diff --git a/Julia/Conditional Statements/conditional_statements.jl b/Julia/Conditional Statements/conditional_statements.jl new file mode 100644 index 00000000..742a4a77 --- /dev/null +++ b/Julia/Conditional Statements/conditional_statements.jl @@ -0,0 +1,9 @@ +# Conditional statements in Julia +# Navendu Pottekkat | 2020 | Apache-2.0 License +# https://www.apache.org/licenses/LICENSE-2.0 + +if true + println("It's true!") +else + println("It's false!") +end diff --git a/Julia/Functions/functions.jl b/Julia/Functions/functions.jl new file mode 100644 index 00000000..29cc7a10 --- /dev/null +++ b/Julia/Functions/functions.jl @@ -0,0 +1,9 @@ +# Functions in Julia +# Navendu Pottekkat | 2020 | Apache-2.0 License +# https://www.apache.org/licenses/LICENSE-2.0 + +function vol_sphere(r) + # Julia allows Unicode names (in UTF-8 encoding) + # Either "pi" or the symbol π can be used + return 4/3*pi*r^3 +end diff --git a/Julia/Hello World/hello_world.jl b/Julia/Hello World/hello_world.jl new file mode 100644 index 00000000..b1d8a4b1 --- /dev/null +++ b/Julia/Hello World/hello_world.jl @@ -0,0 +1,5 @@ +# Hello World! in Julia +# Navendu Pottekkat | 2020 | Apache-2.0 License +# https://www.apache.org/licenses/LICENSE-2.0 + +println("Hello World!") diff --git a/Julia/Loops/for_loops.jl b/Julia/Loops/for_loops.jl new file mode 100644 index 00000000..c996653f --- /dev/null +++ b/Julia/Loops/for_loops.jl @@ -0,0 +1,7 @@ +# for loops in Julia +# Navendu Pottekkat | 2020 | Apache-2.0 License +# https://www.apache.org/licenses/LICENSE-2.0 + +for i in 1:5 + print(i, ", ") +end diff --git a/Julia/README.md b/Julia/README.md new file mode 100644 index 00000000..cb446f33 --- /dev/null +++ b/Julia/README.md @@ -0,0 +1,5 @@ +

+ +

+ +# Julia \ No newline at end of file diff --git a/Julia/logo.svg b/Julia/logo.svg new file mode 100644 index 00000000..c608baf0 --- /dev/null +++ b/Julia/logo.svg @@ -0,0 +1,10 @@ + + + + + + + + + +