Timeline for Count sum of all digits
Current License: CC BY-SA 3.0
28 events
when toggle format | what | by | license | comment | |
---|---|---|---|---|---|
Feb 12, 2014 at 0:27 | history | edited | unclemeat | CC BY-SA 3.0 |
added 1 characters in body
|
Jan 22, 2014 at 23:16 | history | edited | unclemeat | CC BY-SA 3.0 |
added 220 characters in body
|
Jan 22, 2014 at 22:09 | history | edited | unclemeat | CC BY-SA 3.0 |
Realized that appending the second line to the first with & causes problems with delayed expansion
|
Jan 22, 2014 at 21:59 | history | edited | unclemeat | CC BY-SA 3.0 |
didn't need the @ for setlocal
|
Jan 21, 2014 at 0:48 | history | edited | unclemeat | CC BY-SA 3.0 |
deleted 5 characters in body
|
Jan 20, 2014 at 2:33 | history | edited | unclemeat | CC BY-SA 3.0 |
[Edit removed during grace period]
|
Jan 20, 2014 at 1:54 | history | edited | unclemeat | CC BY-SA 3.0 |
deleted 3 characters in body
|
Jan 20, 2014 at 1:39 | history | edited | unclemeat | CC BY-SA 3.0 |
removed @ symbol preceding second for loop.
|
Jan 17, 2014 at 2:40 | history | edited | unclemeat | CC BY-SA 3.0 |
added 242 characters in body
|
Jan 17, 2014 at 2:11 | history | edited | unclemeat | CC BY-SA 3.0 |
added 3 characters in body
|
Jan 17, 2014 at 1:41 | comment | added | unclemeat | Does this answer qualify for the -100 bonus? | |
Jan 17, 2014 at 1:31 | history | edited | unclemeat | CC BY-SA 3.0 |
deleted 11 characters in body
|
Jan 17, 2014 at 1:25 | history | edited | unclemeat | CC BY-SA 3.0 |
added 11 characters in body
|
Jan 17, 2014 at 0:09 | history | edited | unclemeat | CC BY-SA 3.0 |
deleted 1 characters in body
|
Jan 16, 2014 at 23:58 | history | edited | unclemeat | CC BY-SA 3.0 |
removed unnecessary whitespace as well as -Command switch for powershell command
|
Jan 16, 2014 at 23:01 | comment | added | unclemeat | Haha, of course, I just like doing challenges that batch is really not suited for. | |
Jan 16, 2014 at 22:59 | comment | added | Iszi | I will give Batch some good credit for defaulting to integer division, though. That's something PowerShell is missing entirely. | |
Jan 16, 2014 at 22:58 | history | edited | unclemeat | CC BY-SA 3.0 |
added 430 characters in body
|
Jan 16, 2014 at 22:52 | comment | added | Iszi |
Batch won't work. It's limited to (2^31)-1 (signed 32-bit integer). The challenge requires handling of inputs up to (2^64)-1 (unsigned 64-bit integer, but the output for that value would overflow it). This is where PowerShell has a distinct advantage - its [decimal] type allows for values up to (2^96)-1.
|
|
Jan 16, 2014 at 22:09 | history | edited | unclemeat | CC BY-SA 3.0 |
deleted 63 characters in body
|
Jan 16, 2014 at 22:03 | history | edited | unclemeat | CC BY-SA 3.0 |
removed quotation marks surrounding !a:~%%c,1!
|
Jan 16, 2014 at 21:53 | history | edited | unclemeat | CC BY-SA 3.0 |
Removed some unnecessary white space.
|
Jan 16, 2014 at 21:43 | history | edited | unclemeat | CC BY-SA 3.0 |
Was able to take out quotation marks surrounding usebackq in second for loop
|
Jan 16, 2014 at 21:37 | comment | added | unclemeat | Well spotted, Thanks. Will change that now. | |
Jan 16, 2014 at 20:06 | comment | added | Mark | Oops, I see now why you kept your temp variable (for the bonus points). The PowerShell tip still stands, though... | |
Jan 16, 2014 at 19:00 | comment | added | Mark |
Nice solution! There are a few ways to golf this down. 1. You can get rid of the temporary variable v and use %1 directly. 2. You can subtract 1 within your PowerShell script rather than the lengthy @set /a b=%%b-1 which saves you a bunch. With those changes, I have it down to 211 from the original 240. :-)
|
|
Jan 16, 2014 at 5:54 | review | First posts | |||
Jan 16, 2014 at 6:47 | |||||
Jan 16, 2014 at 5:38 | history | answered | unclemeat | CC BY-SA 3.0 |