Hey guys, I think I burnt out of making gists so expect me to be more inactive.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
import 'dart:io' | |
void main() { | |
print("Oh, user, I haven't seen you in a while! How many days have passed?"); | |
String? passedDays = stdin.readLineSync(); | |
if (passedDays != null) { | |
print("Oh man, It's been $passedDays since I have seen you! Hopefully you are fine."); | |
} | |
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
print("Welcome!") | |
myRandomInteger = input("Input a number between 1 and 1000: ") | |
if myRandomInteger >= 10: | |
print("Why?") | |
elif myRandomInteger >= 100: | |
print("Ok, a nice number.") | |
elif myRandomInteger >= 1000: | |
print("Not bad.") |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
(def myVector [251 456 345]) | |
(def myList '(3782 22536 14357)) | |
(println "Your current vector: " myVector) | |
(println "Your current list: " myList) | |
;; Messing with both | |
(conj myVector 234 1556 478) | |
(println myVector) | |
(conj myList 2342515 54536271 35362617) |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
(defn localMessageSys [message] | |
(println "Your message: ") | |
(str message)) | |
(defn recieverMessageSys [receiverMessage] | |
(println "The other person's message: ") | |
(str receiverMessage)) | |
(localMessageSys "Hello, Friend!") | |
(recieverMessageSys "Hello, what's up?") |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
def Hello(): Unit = | |
println("Hello World!") |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
(def myList '(251 45)) | |
(first myList) | |
(println myList) | |
(def myList2 '("yes" "no" "maybe")) | |
(third myList2) | |
(println myList2) | |
(println myList myList2) |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Console.WriteLine("Please input the number of the base of the triangle. "); | |
int triangleBase = Convert.toInt32(Console.ReadLine()); | |
Console.WriteLine("Please input the number of the height of the triangle. "); | |
int triangleHeight = Convert.toInt32(Console.ReadLine()); | |
Console.WriteLine("Joining..."); | |
int result = triangleBase * triangleHeight / 2; | |
Console.WriteLine($"Done! Your result: {result}"); |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
(defn messagesys [message] | |
(println "Your message: ") | |
(str message)) | |
(messagesys "I love Clojure <3") |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
import 'dart:io'; | |
void main() { | |
for (int i = 1; i < 1000000000; i++) { | |
print(i); | |
} | |
// Good luck with this one. | |
print("Enter your password (any): "); | |
String? password = stdin.readLineSync(); | |
if (password != null) { | |
print("Thanks for $password, now have access to your account (I do not)"); |
NewerOlder