Re: [gcj] Question about Code Jam 2019 Round 1B second problem - Draupnir
On Tuesday, April 30, 2019 at 11:19:29 PM UTC+5:30, DahliaSR wrote: > Hello, > > > >> "But, for example after 68 days, it will contribute R1*2^5 rings to the > >> total rings, right?" > > > That's wrong! It still does contribute 0. > The number of R1 contributes 0 total for ANY day larger then 62. > Why is that? : > Day 63: R1 * 2^63 ≡ 0 (mod 2^63) 2^63 is a multiple of 2^63 so the > remainder MUST be 0 > Day 64: R1 * 2^64 ≡ 0 (mod 2^63) 2^63 is a multiple of 2^63 so the > remainder MUST be 0 > R1 * 2^(63 + 1) ≡ 0 (mod 2^63) 2^64 is less than 2^63 > and therefore a multiple 2^63 so the remainder STILL MUST be 0. > > > So when querying day 324, you can ONLY identify R(6) at day 0. > > > Am Di., 30. Apr. 2019 um 17:35 Uhr schrieb Ramesh Kumar : > On Tuesday, April 30, 2019 at 8:18:56 PM UTC+5:30, /dev/joe wrote: > > > The 1-day rings duplicate every day, so their contribution to the sum moves > > one bit left in the binary representation every day. After 63 days, since > > we only get the value mod 2^63, the 1-day rings make no contribution to the > > value you get. > > > > > > > > > On Tue, Apr 30, 2019 at 10:05 AM Ramesh Kumar wrote: > > > Hi All, > > > > > > > > > > > > It was mentioned we can use two chances for Code Jam 2019 Round 1B second > > problem - Draupnir. But I think we can use only one number 324 which is > > sufficient and find the solution. But, I am unable to get the accepted > > answer. Is there anything wrong to use only 324 number to find all the > > required six numbers? Please help me to understand. > > > > > > > > > > > > -- > > > > > > You received this message because you are subscribed to the Google Groups > > "Google Code Jam" group. > > > > > > To unsubscribe from this group and stop receiving emails from it, send an > > email to googl...@googlegroups.com. > > > > > > To post to this group, send email to googl...@googlegroups.com. > > > > > > To view this discussion on the web visit > > https://groups.google.com/d/msgid/google-code/10442015-c57d-4edd-9ac4-dce29cd20eb2%40googlegroups.com. > > > > > > For more options, visit https://groups.google.com/d/optout. > > > > But, for example after 68 days, it will contribute R1*2^5 rings to the total > rings, right? > > > > -- > > You received this message because you are subscribed to the Google Groups > "Google Code Jam" group. > > To unsubscribe from this group and stop receiving emails from it, send an > email to googl...@googlegroups.com. > > To post to this group, send email to googl...@googlegroups.com. > > To view this discussion on the web visit > https://groups.google.com/d/msgid/google-code/c27fe3f0-935e-4ce9-bdcf-b3f31fb422f9%40googlegroups.com. > > For more options, visit https://groups.google.com/d/optout. Thank you all for the explanation. Now I understood what was my mistake which cost me the qualification to Round 2. I had little confusion in calculating modulo. Now I am clear. One last chance I have in Round 1C. I have to wait and see if I can clear the round. -- You received this message because you are subscribed to the Google Groups "Google Code Jam" group. To unsubscribe from this group and stop receiving emails from it, send an email to google-code+unsubscr...@googlegroups.com. To post to this group, send email to google-code@googlegroups.com. To view this discussion on the web visit https://groups.google.com/d/msgid/google-code/bac7360a-619e-40e5-81fc-f5e1cd29d9aa%40googlegroups.com. For more options, visit https://groups.google.com/d/optout.
Re: [gcj] Question about Code Jam 2019 Round 1B second problem - Draupnir
Quick fix of my typos: Day 64: R1 * 2^64 ≡ 0 (mod 2^63) 2^64 is a multiple of 2^63 so the remainder MUST be 0 OR R1 * 2^(63 + 1) ≡ 0 (mod 2^63) 2^64 is NOT less than 2^63 and therefore a multiple 2^63 so the remainder STILL MUST be 0. -- You received this message because you are subscribed to the Google Groups "Google Code Jam" group. To unsubscribe from this group and stop receiving emails from it, send an email to google-code+unsubscr...@googlegroups.com. To post to this group, send email to google-code@googlegroups.com. To view this discussion on the web visit https://groups.google.com/d/msgid/google-code/97b516e6-316b-4642-b3b2-2caa5ed1c0b9%40googlegroups.com. For more options, visit https://groups.google.com/d/optout.
Re: [gcj] Question about Code Jam 2019 Round 1B second problem - Draupnir
Hello, >> "But, for example after 68 days, it will contribute R1*2^5 rings to the total rings, right?" That's wrong! It still does contribute 0. The number of R1 contributes 0 total for ANY day larger then 62. Why is that? : Day 63:R1 * 2^63 ≡ 0 (mod 2^63)2^63 is a multiple of 2^63 so the remainder MUST be 0 Day 64:R1 * 2^64 ≡ 0 (mod 2^63)2^63 is a multiple of 2^63 so the remainder MUST be 0 R1 * 2^(63 + 1) ≡ 0 (mod 2^63)2^64 is less than 2^63 and therefore a multiple 2^63 so the remainder STILL MUST be 0. So when querying day 324, you can ONLY identify R(6) at day 0. Am Di., 30. Apr. 2019 um 17:35 Uhr schrieb Ramesh Kumar < rameshkuma...@gmail.com>: > On Tuesday, April 30, 2019 at 8:18:56 PM UTC+5:30, /dev/joe wrote: > > The 1-day rings duplicate every day, so their contribution to the sum > moves one bit left in the binary representation every day. After 63 days, > since we only get the value mod 2^63, the 1-day rings make no contribution > to the value you get. > > > > > > On Tue, Apr 30, 2019 at 10:05 AM Ramesh Kumar > wrote: > > Hi All, > > > > > > > > It was mentioned we can use two chances for Code Jam 2019 Round 1B > second problem - Draupnir. But I think we can use only one number 324 > which is sufficient and find the solution. But, I am unable to get the > accepted answer. Is there anything wrong to use only 324 number to find all > the required six numbers? Please help me to understand. > > > > > > > > -- > > > > You received this message because you are subscribed to the Google > Groups "Google Code Jam" group. > > > > To unsubscribe from this group and stop receiving emails from it, send > an email to googl...@googlegroups.com. > > > > To post to this group, send email to googl...@googlegroups.com. > > > > To view this discussion on the web visit > https://groups.google.com/d/msgid/google-code/10442015-c57d-4edd-9ac4-dce29cd20eb2%40googlegroups.com > . > > > > For more options, visit https://groups.google.com/d/optout. > > But, for example after 68 days, it will contribute R1*2^5 rings to the > total rings, right? > > -- > You received this message because you are subscribed to the Google Groups > "Google Code Jam" group. > To unsubscribe from this group and stop receiving emails from it, send an > email to google-code+unsubscr...@googlegroups.com. > To post to this group, send email to google-code@googlegroups.com. > To view this discussion on the web visit > https://groups.google.com/d/msgid/google-code/c27fe3f0-935e-4ce9-bdcf-b3f31fb422f9%40googlegroups.com > . > For more options, visit https://groups.google.com/d/optout. > -- You received this message because you are subscribed to the Google Groups "Google Code Jam" group. To unsubscribe from this group and stop receiving emails from it, send an email to google-code+unsubscr...@googlegroups.com. To post to this group, send email to google-code@googlegroups.com. To view this discussion on the web visit https://groups.google.com/d/msgid/google-code/CAEWn8ogz54D5zbosjyk0zZvhiCkZbUT4N5z5d6F8Zh-Ew7hoZQ%40mail.gmail.com. For more options, visit https://groups.google.com/d/optout.
Re: [gcj] Question about Code Jam 2019 Round 1B second problem - Draupnir
On Tuesday, April 30, 2019 at 8:18:56 PM UTC+5:30, /dev/joe wrote: > The 1-day rings duplicate every day, so their contribution to the sum moves > one bit left in the binary representation every day. After 63 days, since we > only get the value mod 2^63, the 1-day rings make no contribution to the > value you get. > > > On Tue, Apr 30, 2019 at 10:05 AM Ramesh Kumar wrote: > Hi All, > > > > It was mentioned we can use two chances for Code Jam 2019 Round 1B second > problem - Draupnir. But I think we can use only one number 324 which is > sufficient and find the solution. But, I am unable to get the accepted > answer. Is there anything wrong to use only 324 number to find all the > required six numbers? Please help me to understand. > > > > -- > > You received this message because you are subscribed to the Google Groups > "Google Code Jam" group. > > To unsubscribe from this group and stop receiving emails from it, send an > email to googl...@googlegroups.com. > > To post to this group, send email to googl...@googlegroups.com. > > To view this discussion on the web visit > https://groups.google.com/d/msgid/google-code/10442015-c57d-4edd-9ac4-dce29cd20eb2%40googlegroups.com. > > For more options, visit https://groups.google.com/d/optout. But, for example after 68 days, it will contribute R1*2^5 rings to the total rings, right? -- You received this message because you are subscribed to the Google Groups "Google Code Jam" group. To unsubscribe from this group and stop receiving emails from it, send an email to google-code+unsubscr...@googlegroups.com. To post to this group, send email to google-code@googlegroups.com. To view this discussion on the web visit https://groups.google.com/d/msgid/google-code/c27fe3f0-935e-4ce9-bdcf-b3f31fb422f9%40googlegroups.com. For more options, visit https://groups.google.com/d/optout.
Re: [gcj] Question about Code Jam 2019 Round 1B second problem - Draupnir
The 1-day rings duplicate every day, so their contribution to the sum moves one bit left in the binary representation every day. After 63 days, since we only get the value mod 2^63, the 1-day rings make no contribution to the value you get. On Tue, Apr 30, 2019 at 10:05 AM Ramesh Kumar wrote: > Hi All, > > It was mentioned we can use two chances for Code Jam 2019 Round 1B second > problem - Draupnir. But I think we can use only one number 324 which is > sufficient and find the solution. But, I am unable to get the accepted > answer. Is there anything wrong to use only 324 number to find all the > required six numbers? Please help me to understand. > > -- > You received this message because you are subscribed to the Google Groups > "Google Code Jam" group. > To unsubscribe from this group and stop receiving emails from it, send an > email to google-code+unsubscr...@googlegroups.com. > To post to this group, send email to google-code@googlegroups.com. > To view this discussion on the web visit > https://groups.google.com/d/msgid/google-code/10442015-c57d-4edd-9ac4-dce29cd20eb2%40googlegroups.com > . > For more options, visit https://groups.google.com/d/optout. > -- You received this message because you are subscribed to the Google Groups "Google Code Jam" group. To unsubscribe from this group and stop receiving emails from it, send an email to google-code+unsubscr...@googlegroups.com. To post to this group, send email to google-code@googlegroups.com. To view this discussion on the web visit https://groups.google.com/d/msgid/google-code/CAMAzhzho0Ld2mfWKTPs2ELsWKVOCG0KXO98_MMUkOiHm1NrzWw%40mail.gmail.com. For more options, visit https://groups.google.com/d/optout.
[gcj] Question about Code Jam 2019 Round 1B second problem - Draupnir
Hi All, It was mentioned we can use two chances for Code Jam 2019 Round 1B second problem - Draupnir. But I think we can use only one number 324 which is sufficient and find the solution. But, I am unable to get the accepted answer. Is there anything wrong to use only 324 number to find all the required six numbers? Please help me to understand. -- You received this message because you are subscribed to the Google Groups "Google Code Jam" group. To unsubscribe from this group and stop receiving emails from it, send an email to google-code+unsubscr...@googlegroups.com. To post to this group, send email to google-code@googlegroups.com. To view this discussion on the web visit https://groups.google.com/d/msgid/google-code/10442015-c57d-4edd-9ac4-dce29cd20eb2%40googlegroups.com. For more options, visit https://groups.google.com/d/optout.