2023-03-28

This commit is contained in:
2023-03-28 14:19:42 +09:00
parent 069e9e09e8
commit b64d8d0806
3 changed files with 31 additions and 1 deletions

4
src/hello.jl Executable file
View File

@@ -0,0 +1,4 @@
#!/snap/bin/julia
name = "World"
println("Hello, $name.")

26
src/numbers.jl Executable file
View File

@@ -0,0 +1,26 @@
#!/snap/bin/julia
x = 11
println(typeof(x))
y = 11.8
println(typeof(y))
println(Sys.WORD_SIZE) # 32 or 64 ...
println(typemax(Int))
println(typemin(Int))
a = 2.5e-4
println(typeof(a)) # Float64
b = 2.5f-4
println(typeof(b)) # Float32
arr = [1,2,3]
println(arr .^ 2) # [1,4,9]
println(sin.(arr))
c = 2//3 + 1
println(c) # 5//3

View File

@@ -1,4 +1,4 @@
#!/usr/bin/julia
#!/snap/bin/julia
x = 10
y = 1