This file contains hidden or 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
| .container { | |
| margin: 100px auto; | |
| width: 600px; | |
| } | |
| .col-sm-4 { | |
| margin-bottom: -100px; | |
| } | |
| .login { | |
| position: relative; | |
| margin: 0 auto; |
This file contains hidden or 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
| while True : | |
| try : | |
| n = input("Please enter an integer") | |
| n=int(n) | |
| break | |
| except ValueError : | |
| print ("No valid Integer! Please Enter again") | |
| print ("Great, you successfully entered an integer") |
This file contains hidden or 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
| a = int(input("Enter a no.")) | |
| b = int(input("Enter a no.")) | |
| c = str(input("Enter a mathematical function")) | |
| def calculator(c): | |
| return{ | |
| '+': a+b, | |
| '-': a-b, | |
| '*': a*b, | |
| '/': a/b, | |
| }.get(c) |
This file contains hidden or 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
| i=int(input("Enter days in the year")) | |
| if i==366: | |
| print("The year is a leap year") | |
| elif i==365: | |
| print ("The year is not a leap year") | |
| else: | |
| print ("Year not valid") |