├── .gitpod.yml ├── LICENSE ├── README.md └── simpleGame.py /.gitpod.yml: -------------------------------------------------------------------------------- 1 | tasks: 2 | - command: python3 simpleGame.py 3 | -------------------------------------------------------------------------------- /LICENSE: -------------------------------------------------------------------------------- 1 | MIT License 2 | 3 | Copyright (c) 2019 Tech With Tim 4 | 5 | Permission is hereby granted, free of charge, to any person obtaining a copy 6 | of this software and associated documentation files (the "Software"), to deal 7 | in the Software without restriction, including without limitation the rights 8 | to use, copy, modify, merge, publish, distribute, sublicense, and/or sell 9 | copies of the Software, and to permit persons to whom the Software is 10 | furnished to do so, subject to the following conditions: 11 | 12 | The above copyright notice and this permission notice shall be included in all 13 | copies or substantial portions of the Software. 14 | 15 | THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR 16 | IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, 17 | FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE 18 | AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER 19 | LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, 20 | OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE 21 | SOFTWARE. 22 | -------------------------------------------------------------------------------- /README.md: -------------------------------------------------------------------------------- 1 | # Simple-Python-Game 2 | A small, simple, text based game. 3 | 4 | # 💻 Launch Your Software Development Career Today! 5 | 6 | 🎓 **No degree? No problem!** My program equips you with everything you need to break into tech and land an entry-level software development role. 7 | 8 | 🚀 **Why Join?** 9 | - 💼 **$70k+ starting salary potential** 10 | - 🕐 **Self-paced:** Complete on your own time 11 | - 🤑 **Affordable:** Low risk compared to expensive bootcamps or degrees 12 | - 🎯 **45,000+ job openings** in the market 13 | 14 | 👉 **[Start your journey today!](https://techwithtim.net/dev)** 15 | No experience needed—just your determination. Future-proof your career and unlock six-figure potential like many of our students have! 16 | -------------------------------------------------------------------------------- /simpleGame.py: -------------------------------------------------------------------------------- 1 | # Simple game in python 2 | 3 | print('Hi, welcome to the Tim quiz!') 4 | print('Try to get as many questions correct as possible...') 5 | 6 | totalQuestions = 4 7 | score = 0 8 | 9 | ans = input('1. What is the name of my youtube channel? ') 10 | 11 | if ans.lower() == 'tech with tim': 12 | print('Correct!') 13 | score += 1 14 | else: 15 | print('Incorrect') 16 | 17 | 18 | ans = input('2. What is my age? ') 19 | 20 | if ans == "17": 21 | print('Correct!') 22 | score += 1 23 | else: 24 | print('Incorrect') 25 | 26 | 27 | ans = input('3. What is my favourite sport? ') 28 | 29 | if ans.lower() == "soccer": 30 | print('Correct!') 31 | score += 1 32 | else: 33 | print('Incorrect') 34 | 35 | 36 | ans = input('4. What is my favourite food? ') 37 | 38 | if ans.lower() == "pizza": 39 | print('Correct!') 40 | score += 1 41 | else: 42 | print('Incorrect') 43 | 44 | 45 | print("Thank you for playing, you got " + str(score) + ' questions correct!' ) 46 | percent = (score/totalQuestions) * 100 47 | print("Mark: " + str(int(percent)) + '%') 48 | 49 | if percent >= 50: 50 | print('Nice! You passed!') 51 | else: 52 | print('Better luck next time') 53 | 54 | 55 | 56 | 57 | 58 | 59 | 60 | 61 | 62 | 63 | 64 | 65 | 66 | 67 | --------------------------------------------------------------------------------