Skip to content

Instantly share code, notes, and snippets.

@RafaelC457ro
Created July 3, 2018 17:32
Show Gist options
  • Save RafaelC457ro/24b2e90d7449ccac8a4d7d818420b08b to your computer and use it in GitHub Desktop.
Save RafaelC457ro/24b2e90d7449ccac8a4d7d818420b08b to your computer and use it in GitHub Desktop.
pseudo code url shortener
while not quit do
read user input into string
parse string to struct using lexer()
if struct is type of SET do
generate key using base62 using struct data
insert key data into map
prinf "success"
else if struct is type of GET do
if find key in array do
prinf value
else
print "not found"
endif
else
print "not valid command"
endif
endwhile
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment