diff --git a/Python/calculator.py b/Python/calculator.py new file mode 100644 index 0000000..08488df --- /dev/null +++ b/Python/calculator.py @@ -0,0 +1,9 @@ +x = int(input("x: ")) + + +y = int(input("y: ")) + + +z = x / y + +print(f"{z:.50f}") #incantation diff --git a/Python/cat.py b/Python/cat.py index ba4ce7e..05d6ad9 100644 --- a/Python/cat.py +++ b/Python/cat.py @@ -1,3 +1,9 @@ -for _ i in range(3): - print("Meow") +def main(): + for i in range(3): + meow() +def meow(): + print("meow") + +if __name__ == "__main__": + main() diff --git a/Python/dictionary.py b/Python/dictionary.py index cabc1db..6d73135 100644 --- a/Python/dictionary.py +++ b/Python/dictionary.py @@ -3,13 +3,16 @@ words = set() def check(word): return word.lower() in words + def load(dictionary): with open(dictionary) as file: words.update(file.read().splitlines()) return True - def size(): + +def size(): return len(words) - def unload(): + +def unload(): return True diff --git a/Python/hello.py b/Python/hello.py index 94e67f0..c652b8e 100644 --- a/Python/hello.py +++ b/Python/hello.py @@ -1 +1,3 @@ -print ("Hello World") + +answer = input("What's your name? ") +print(f"hello, {answer}") diff --git a/Python/uppercase1.py b/Python/uppercase1.py new file mode 100644 index 0000000..73fe4f8 --- /dev/null +++ b/Python/uppercase1.py @@ -0,0 +1,3 @@ +before = input("Before: ") +after = before.upper() +print(f"After: {after}") diff --git a/hello1 b/hello1 new file mode 100755 index 0000000..f125449 Binary files /dev/null and b/hello1 differ diff --git a/hello1.c b/hello1.c new file mode 100644 index 0000000..7ef1106 --- /dev/null +++ b/hello1.c @@ -0,0 +1,10 @@ +#include +#include + +int main(void) + +{ + string answer = get_string("What's your name? "); + printf("hello, %s\n, answer); +} + diff --git a/hello2 b/hello2 new file mode 100755 index 0000000..f125449 Binary files /dev/null and b/hello2 differ