Created
November 4, 2017 12:14
-
-
Save gagan-bansal/c6b7212f613fe2d74d231e12216c31df to your computer and use it in GitHub Desktop.
ex1 created by GaganBansal - https://repl.it/NjwU/1
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 "Enter the password" | |
INPUT WORD$ | |
IF WORD$ = "SECRET" THEN | |
PRINT "permission granted" | |
ELSE | |
PRINT "permission denied": GOTO goend | |
END IF | |
PRINT "what should I call you" | |
INPUT name | |
PRINT "Hi "; name; "! How old are you" | |
INPUT age | |
diff = 42 - age | |
PRINT "I am 42, so "; diff; " years elder than you" | |
PRINT "where do you live?" | |
INPUT place$ | |
IF place$ = "Kharghar" THEN | |
PRINT place$; " is such a nice place. I also live in "; place$ | |
ELSE | |
PRINT "My friend also live in "; place$ | |
END IF | |
goend: | |
PRINT "OK bye" |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment