Skip to main content

Timeline for Bytes/Character

Current License: CC BY-SA 3.0

9 events
when toggle format what by license comment
Jun 25, 2016 at 1:59 comment added Dennis Is that really a problem? for c=s doesn't iterate over indices, but over characters.
Jun 24, 2016 at 20:46 comment added Alex A. @Dennis That will fail for non-indexable strings. (Can't think of an example offhand though.)
Jun 24, 2016 at 20:45 comment added Alex A. @Neil No, split("", "") == [""], i.e. a one-element array containing an empty string, but the issue is that sizeof("") == 0, which the OP said is not allowed.
Jun 24, 2016 at 11:26 comment added cat @Neil split("","") appears to give "" (unlike in Python which gives an exception) but I don't know anything about the compatibility of [] and "" in julia.
Jun 24, 2016 at 7:52 comment added Neil Odd; does split("","") not return []? (JavaScript's "".split("") does.)
Jun 24, 2016 at 0:33 comment added Dennis s->[sizeof("$c")for c=s] saves a few bytes.
Jun 24, 2016 at 0:22 history edited Dennis CC BY-SA 3.0
deleted 54 characters in body
Jun 23, 2016 at 16:51 history edited Alex A. CC BY-SA 3.0
deleted 191 characters in body
Jun 23, 2016 at 16:44 history answered Alex A. CC BY-SA 3.0