📚 This video is a walkthrough of solving problem set 9 of CS50's Finance module.
💻 The goal is to build a website where users can buy and sell shares, requiring registration and login functionality.
🔑 To access share values, an API call is made using a registered API key.
✅ Registering a new user by hashing their password and adding them to the database.
🔒 Storing user information using session and redirecting them to their account after registration.
📈 Implementing a route to allow users to look up a stock's current price.
✅ The lookup function in helpers.py connects to the API using an API key and retrieves stock information based on a symbol.
📊 If the stock symbol exists, the lookup function returns the name, price, and symbol of the stock. Otherwise, it returns that the symbol doesn't exist.
💰 The quoted.html file receives the stock information from the lookup function and displays the name, price, and symbol of the stock.
📉📈 The buy route allows users to enter a symbol and the number of shares they want to buy. It checks if the user can afford the shares at the current price and updates the database with the transaction details.
💰 Calculating the transaction value by multiplying the number of shares with the stock price.
💸 Checking if the user has enough money by comparing their cash with the transaction value.
🔄 Updating the user's cash by subtracting the transaction value and updating the transaction table with the user ID, symbol, shares, price, and date.
💡 Extract relevant information about the user and their transactions to display in a table on the website.
💰 Calculate the total amount of shares and cash the user has.
📊 Create an HTML table using the extracted information to display the user's portfolio.
💡 Creating a new row in the table to display the total cash amount.
📊 Implementing the sell functionality to allow users to sell shares.
🔒 Performing various checks to ensure the user enters valid information and updating the user's cash and transaction tables accordingly.
The video covers the implementation of a feature that allows users to sell shares based on their account balance.
The video shows how to summarize and display the user's transaction history on their account.
The video also demonstrates adding a personal touch by allowing users to add additional cash to their accounts.
Petrolina exploradora te explica cómo es el mundo del petróleo
Practice: From Novice to Virtuoso
Caso Hipotético | Juicio de Divorcio con Incidente de Pensión Alimenticia
Cortometraje contra la violencia de género | Callar duele mas
GERUNDS & INFINITIVES | WINNING is everything? OR TO WIN is everything?
Will We Ever Run Out of New Music?