June 2018 Update

This commit is contained in:
Ingy döt Net 2018-06-22 20:57:24 +00:00
parent ba8067c3b7
commit 22f33d4004
5278 changed files with 84726 additions and 14379 deletions

View file

@ -0,0 +1,9 @@
import extensions.
program =
[
literal s := "12345".
s := s toInt + 1.
console printLine(s).
].

View file

@ -0,0 +1,9 @@
I8 *s;
s = "10";
s = Str2I64(s) + 1;
Print("%d\n", s);
s = "-10";
s = Str2I64(s) + 1;
Print("%d\n", s);

View file

@ -1,3 +1,5 @@
import Base.+
Base.:+(s::AbstractString, n::Real) = string(parse(s) + n)
+(s::String, n::Integer) = string(parse(Int, s) + n)
@show "125" + 1
@show "125.15" + 1
@show "1234567890987654321" + 1

View file

@ -1 +1 @@
Print[FromDigits["1234"] + 1]
FromDigits["1234"] + 1