Project Description¶

This project is called Flashcard that was inspired by Quizlet, a selflearning tool with flashcards. People can use flashcards to help themselves practice and master what they're learning.

Flashcard has the following commands:

User System:

  1. signup - create user account
  2. login - login into the user account and get access to the user's flashcard collection (switch to card system)
  3. show user - show the current existed account (only username)
  4. end - end the program

Card System:

  1. add - add card to the flashcard collection
  2. remove - remove card from the flashcard collection
  3. show card - show the current flashcard collection
  4. quiz - take a quiz in a designed order and focus by user
  5. logout - logout the account and back to the user system

This project contain two systems (user system and card system). Once the program is executed, it starts with the user system. User can create their account to have their own flashcard collection. After they create the account, they must login into the account to get access to their own flashcard collection. In addition, user can also see the current existed account (only the username) in the user system.

Once the user login into their account, they are switch to the card system. In the card system, user can view their flashcard collection and add and remove cards in the collection. In addition, user can also quiz themselves from the collection to check their understanding. The quiz can be designed with specific order and focus by user. Once they finish the quiz, it will pop out the feedback of quiz to the user. If the user is done for their flashcard collection, they can logout their account and back to the user system. Then, user can choose to re-login or signup a new account or end the program.

Project Code¶

In [1]:
from my_module.classes import *
from my_module.functions import *

Because the output is too long, so I will present the user system and the card system separately.

We first need to use User system to create accounts. The following output presents you what different responses you will receive if you signup a new account, login into a unexisted account, login into a correct account, and logout the account.

In [2]:
system = User()
start(system)
Hi! Welcome To Flashcards!

Instructions:
1. If you are the first time user, please type 'signup' to create your own flashcards!
2. If you've already have account, please type 'login' to access your flashcards!
3. If you want to see the current existed username, please type 'show user' to access the username list~
4. If you've done learning, please type 'end' to end the program!

Current Command: signup, login, show user, end
Please enter your command:signup
Please enter a username:viki
Please create a password for this account:123

You have created an account successfully!
Please try to login into your account! 

Current Command: signup, login, show user, end
Please type your command:signup
Please enter a username:jason
Please create a password for this account:456

You have created an account successfully!
Please try to login into your account! 

Current Command: signup, login, show user, end
Please type your command:login
Please enter a username:jack
Please enter your password:111

Please check your user name!


Current Command: signup, login, show user, end
Please type your command:show user

Current existed username:
['viki', 'jason']

Current Command: signup, login, show user, end
Please type your command:login
Please enter a username:viki
Please enter your password:123

Welcome back viki!

Inside your flashcard, here are thing you can do:
1. Type 'add' to add a new card into your flashcard collections.
2. Type 'remove' to remove an existed card from your flashcard collections.
3. Type 'show card' to view your current entire flashcard collections.
4. Type 'quiz' to take a quiz on your flashcard collections.
5. Type 'logout' to logout your account.

Enjoy Studying ^v^

Current Command: add, remove, show card, quiz, logout
Please enter your command:logout

See you viki~

Current Command: signup, login, show user, end
Please type your command:wrong command
You should enter one of the above command!

Current Command: signup, login, show user, end
Please type your command:end

Bye~~~~

After we have account, in order to get into the Card system, we must login into the account. We will resume the same program we just ran. The following output will show you how the program process when you add, remove, and show cards and take quiz in the flashcard collection

In [3]:
start(system)
Hi! Welcome To Flashcards!

Instructions:
1. If you are the first time user, please type 'signup' to create your own flashcards!
2. If you've already have account, please type 'login' to access your flashcards!
3. If you want to see the current existed username, please type 'show user' to access the username list~
4. If you've done learning, please type 'end' to end the program!

Current Command: signup, login, show user, end
Please enter your command:login
Please enter a username:viki
Please enter your password:123

Welcome back viki!

Inside your flashcard, here are thing you can do:
1. Type 'add' to add a new card into your flashcard collections.
2. Type 'remove' to remove an existed card from your flashcard collections.
3. Type 'show card' to view your current entire flashcard collections.
4. Type 'quiz' to take a quiz on your flashcard collections.
5. Type 'logout' to logout your account.

Enjoy Studying ^v^

Current Command: add, remove, show card, quiz, logout
Please enter your command:add
Term: string
Definition: text


Current Command: add, remove, show card, quiz, logout
Please enter your command:add
Term: integer
Definition: whole number


Current Command: add, remove, show card, quiz, logout
Please enter your command:add
Term: float
Definition: signed, decimal point


Current Command: add, remove, show card, quiz, logout
Please enter your command:add
Term: boolean
Definition: True or False


Current Command: add, remove, show card, quiz, logout
Please enter your command:show card
term definition
0 string text
1 integer whole number
2 float signed, decimal point
3 boolean True or False

Current Command: add, remove, show card, quiz, logout
Please enter your command:remove
Term: float


Current Command: add, remove, show card, quiz, logout
Please enter your command:show card
term definition
0 string text
1 integer whole number
2 boolean True or False

Current Command: add, remove, show card, quiz, logout
Please enter your command:quiz
Order is random or ordered?random
Focus on term, definition, or mixed?mixed
Explain boolean
True or False
You are correct!
Explain integer
whole number
You are correct!
Explain string
text
You are correct!
Congratulations! You got them all correct!




Current Command: add, remove, show card, quiz, logout
Please enter your command:quiz
Order is random or ordered?random
Focus on term, definition, or mixed?mixed
What is the term for: whole number
I don't know
Nice try! But the answer is: integer
What is the term for: True or False
boolean
You are correct!
Explain string
text
You are correct!
You got wrong on below card(s):
term definition
0 integer whole number



Current Command: add, remove, show card, quiz, logout
Please enter your command:logout

See you viki~

Current Command: signup, login, show user, end
Please type your command:end

Bye~~~~