Recent content by Raghav Gupta

  1. R

    Liquid which turns into a ball?

    Here is a link of water orbs that are 100% eatable and biodegradable. https://www.yahoo.com/news/scientists-created-edible-water-orbs-190204141.html
  2. R

    Liquid which turns into a ball?

    Understood. Thanks all of you. That viscosity concepts are not being applied here. I thought initially that it would have been a different liquid.
  3. R

    Liquid which turns into a ball?

    Is there any liquid based on viscosity and density that changes into ball. Obviously here, the liquid cannot be water. Other thing can be that some chemical is applied in hand( This doesn't make sense I think).
  4. R

    Python Python:Reading (int,float,comp,bool) from file

    But we have to sort, so we have to convert it into numeric type. EDIT: Ok, so we can compare them as strings only. It would compare lexicographically based on ASCII values but if we store them in file again, it is stored something like this- '1' , '2+j', '3.5', '4', 'FALSE', 'TRUE' This is...
  5. R

    Python Python:Reading (int,float,comp,bool) from file

    Homework Statement Read a comma separated numeric (int, float, comp, bool) values from a file and store each comma separated value in a list[/B]. Sort the list (without using in-built sort/sorted function) and write it to output file in comma separated format. In my attempt I am not able to do...
  6. R

    Showing associativity for a particular set

    No, that is okay we can do mod n on both sides or in programming languages (% n). But that we should have get from a*b*c. Why, we have to add something with n on our own? %n or mod n should have come on its own while solving the equation.
  7. R

    Showing associativity for a particular set

    a= nq1 + r1 b= nq2 + r2 c=nq3 + r3 a*(b*c) = a * r2r3 = r1r2r3 (a* b) * c = r1r2 * c = r1r2r3 This is showing associativity but this is wrong as if we take a =1, b=2, c=3, then, 1*2*3= 2 but r1r2r3 = 6 Edit: for n = 4 here
  8. R

    Showing associativity for a particular set

    Hmm.. then it's wrong. Suppose if number are 1,2,3. then 1*2*3 should be 2 but from r1r2r3 answer would be 6 which is essentially 2 for modulo 4. I thought I got an answer from equations. What should I do?
  9. R

    Showing associativity for a particular set

    Thanks, got it. Getting One side as r1r2r3 and other also as some r1r2r3. Which proves associativity.
  10. R

    Showing associativity for a particular set

    Modulo operation I can think of but it is essentially just a operator. I have tried doing this question in many ways. Can this associativity be shown mathematically by equations? Since, by equations I am getting stuck, but I want it to solve using equations.
  11. R

    Showing associativity for a particular set

    For writing remainder as a number I have to use Euclid's division lemma, but it then brings 1 more variable quotient into account here. Associativity of multiplication I can use but remainder hinders it.
  12. R

    Showing associativity for a particular set

    Homework Statement Let Zn denote the set of integers {0,1,2,...n-1}. Let * be a binary operation on Zn such that a*b is the remainder of ab divided by n. Show that (Zn,*) is a semigroup for any n . Homework EquationsThe Attempt at a Solution [/B]For showing the algebraic system to be a...
  13. R

    Storing a number as digits in a linked list

    Thanks, I understand the floor function aka greatest integer function. In Turbo c++ it was not giving a warning or error. I think it takes NULL->next as NULL in turbo c++
  14. R

    Storing a number as digits in a linked list

    Thanks it is working fine now. delAlt() is working fine for me even when there are odd number of digits. For eg: input number: 8475483 (odd number of digits) Output: 8475483 (number as separate digits in link list) 8743 ( deleting alternate nodes)
Back
Top