ECONOMY DASHBOARD IN HTML CSS AND JS

<!DOCTYPE html>
<html lang="en">
<head>
    <meta charset="UTF-8">
    <meta name="viewport" content="width=device-width, initial-scale=1.0">
    <title>Economy Dashboard</title>
    <style>
        body {
            font-family: Arial, sans-serif;
            margin: 0;
            padding: 0;
            background: linear-gradient(to bottom right, #4facfe, #00f2fe);
            color: #333;
        }
        .container {
            max-width: 900px;
            margin: auto;
            padding: 20px;
        }
        h1 {
            text-align: center;
            margin-bottom: 20px;
            color: #fff;
            text-shadow: 1px 1px 3px rgba(0, 0, 0, 0.5);
        }
        .card {
            background: #fff;
            padding: 15px;
            margin-bottom: 20px;
            border-radius: 8px;
            box-shadow: 0 4px 8px rgba(0, 0, 0, 0.2);
        }
        .card h2 {
            font-size: 20px;
            margin-bottom: 10px;
            color: #007bff;
        }
        .input-group {
            margin-bottom: 15px;
        }
        .input-group label {
            display: block;
            font-size: 14px;
            margin-bottom: 5px;
        }
        .input-group input, .input-group select {
            width: 100%;
            padding: 8px;
            font-size: 14px;
            border: 1px solid #ccc;
            border-radius: 4px;
        }
        button {
            background-color: #007bff;
            color: #fff;
            padding: 10px 15px;
            border: none;
            border-radius: 4px;
            cursor: pointer;
            font-size: 16px;
        }
        button:hover {
            background-color: #0056b3;
        }
        .chart {
            margin-top: 20px;
            text-align: center;
        }
        .chart div {
            height: 20px;
            margin: 5px 0;
            background-color: #007bff;
            color: #fff;
            text-align: center;
            border-radius: 4px;
        }
    </style>
</head>
<body>
    <div class="container">
        <h1>Economy Dashboard</h1>

        <!-- Currency Converter -->
        <div class="card">
            <h2>Currency Converter</h2>
            <div class="input-group">
                <label for="amount">Amount:</label>
                <input type="number" id="amount" placeholder="Enter amount">
            </div>
            <div class="input-group">
                <label for="fromCurrency">From Currency:</label>
                <select id="fromCurrency">
                    <option value="USD">USD</option>
                    <option value="EUR">EUR</option>
                    <option value="GBP">GBP</option>
                    <option value="INR">INR</option>
                </select>
            </div>
            <div class="input-group">
                <label for="toCurrency">To Currency:</label>
                <select id="toCurrency">
                    <option value="USD">USD</option>
                    <option value="EUR">EUR</option>
                    <option value="GBP">GBP</option>
                    <option value="INR">INR</option>
                </select>
            </div>
            <button onclick="convertCurrency()">Convert</button>
            <p id="conversionResult"></p>
        </div>

        <!-- GDP Calculator -->
        <div class="card">
            <h2>GDP Calculator</h2>
            <div class="input-group">
                <label for="consumption">Consumption:</label>
                <input type="number" id="consumption" placeholder="Enter consumption">
            </div>
            <div class="input-group">
                <label for="investment">Investment:</label>
                <input type="number" id="investment" placeholder="Enter investment">
            </div>
            <div class="input-group">
                <label for="government">Government Spending:</label>
                <input type="number" id="government" placeholder="Enter government spending">
            </div>
            <div class="input-group">
                <label for="netExports">Net Exports:</label>
                <input type="number" id="netExports" placeholder="Enter net exports">
            </div>
            <button onclick="calculateGDP()">Calculate GDP</button>
            <p id="gdpResult"></p>
        </div>

        <!-- GDP Growth Chart -->
        <div class="card">
            <h2>GDP Growth Chart</h2>
            <button onclick="showGDPChart()">Show Chart</button>
            <div class="chart" id="gdpChart"></div>
        </div>
    </div>

    <script>
        // Currency Converter Logic
        function convertCurrency() {
            const amount = document.getElementById('amount').value;
            const fromCurrency = document.getElementById('fromCurrency').value;
            const toCurrency = document.getElementById('toCurrency').value;

            // Simple conversion rates for demo purposes
            const exchangeRates = {
                "USD": { "EUR": 0.85, "GBP": 0.75, "INR": 74 },
                "EUR": { "USD": 1.18, "GBP": 0.88, "INR": 87 },
                "GBP": { "USD": 1.33, "EUR": 1.14, "INR": 98 },
                "INR": { "USD": 0.013, "EUR": 0.011, "GBP": 0.010 },
            };

            const rate = exchangeRates[fromCurrency][toCurrency];
            if (rate && amount > 0) {
                const convertedAmount = (amount * rate).toFixed(2);
                document.getElementById('conversionResult').innerText =
                    `${amount} ${fromCurrency} = ${convertedAmount} ${toCurrency}`;
            } else {
                document.getElementById('conversionResult').innerText =
                    "Invalid conversion.";
            }
        }

        // GDP Calculator Logic
        function calculateGDP() {
            const consumption = parseFloat(document.getElementById('consumption').value || 0);
            const investment = parseFloat(document.getElementById('investment').value || 0);
            const government = parseFloat(document.getElementById('government').value || 0);
            const netExports = parseFloat(document.getElementById('netExports').value || 0);

            const gdp = consumption + investment + government + netExports;
            document.getElementById('gdpResult').innerText = `Estimated GDP: $${gdp.toFixed(2)} billion`;
        }

        // GDP Growth Chart Logic
        function showGDPChart() {
            const growthData = [2.5, 3.1, 2.8, 3.5, 3.9]; // Example growth rates
            const chart = document.getElementById('gdpChart');
            chart.innerHTML = ""; // Clear previous chart
            growthData.forEach((growth, year) => {
                const bar = document.createElement('div');
                bar.style.width = `${growth * 20}px`;
                bar.innerText = `Year ${year + 1}: ${growth}%`;
                chart.appendChild(bar);
            });
        }
    </script>
</body>
</html>
HTML

Bank Management System Code in Python

import random

# Global dictionary to store account details
accounts = {}

# Display menu
def display_menu():
    print("\nBank Management System")
    print("1. Create Account")
    print("2. Deposit Money")
    print("3. Withdraw Money")
    print("4. Check Balance")
    print("5. Exit")

# Function to create an account
def create_account():
    print("\n=== Create Account ===")
    name = input("Enter your name: ")
    age = int(input("Enter your age: "))
    initial_deposit = float(input("Enter initial deposit amount (minimum $100): "))
    
    if initial_deposit < 100:
        print("Initial deposit must be at least $100.")
        return
    
    # Generate a unique account ID
    account_id = str(random.randint(100000, 999999))
    while account_id in accounts:  # Ensure no duplicate ID
        account_id = str(random.randint(100000, 999999))
    
    # Store the account details
    accounts[account_id] = {
        "name": name,
        "age": age,
        "balance": initial_deposit
    }
    
    print(f"Account created successfully! Your Account ID is {account_id}")

# Function to deposit money
def deposit_money():
    print("\n=== Deposit Money ===")
    account_id = input("Enter your Account ID: ")
    
    if account_id not in accounts:
        print("Invalid Account ID. Please try again.")
        return
    
    deposit_amount = float(input("Enter deposit amount: "))
    if deposit_amount <= 0:
        print("Deposit amount must be greater than zero.")
        return
    
    accounts[account_id]["balance"] += deposit_amount
    print(f"${deposit_amount} deposited successfully. New Balance: ${accounts[account_id]['balance']}")

# Function to withdraw money
def withdraw_money():
    print("\n=== Withdraw Money ===")
    account_id = input("Enter your Account ID: ")
    
    if account_id not in accounts:
        print("Invalid Account ID. Please try again.")
        return
    
    withdraw_amount = float(input("Enter withdrawal amount: "))
    if withdraw_amount <= 0:
        print("Withdrawal amount must be greater than zero.")
        return
    
    if withdraw_amount > accounts[account_id]["balance"]:
        print("Insufficient funds. Transaction denied.")
        return
    
    accounts[account_id]["balance"] -= withdraw_amount
    print(f"${withdraw_amount} withdrawn successfully. Remaining Balance: ${accounts[account_id]['balance']}")

# Function to check balance
def check_balance():
    print("\n=== Check Balance ===")
    account_id = input("Enter your Account ID: ")
    
    if account_id not in accounts:
        print("Invalid Account ID. Please try again.")
        return
    
    print(f"Account Holder: {accounts[account_id]['name']}")
    print(f"Balance: ${accounts[account_id]['balance']}")

# Main program loop
def main():
    while True:
        display_menu()
        choice = input("Enter your choice: ")
        
        if choice == "1":
            create_account()
        elif choice == "2":
            deposit_money()
        elif choice == "3":
            withdraw_money()
        elif choice == "4":
            check_balance()
        elif choice == "5":
            print("Exiting program. Thank you for using the Bank Management System!")
            break
        else:
            print("Invalid choice. Please try again.")

# Run the program
main()
Python

CHHYANDI HYDROPOWER ANNOUNCE FOR ITS AGM

hhyangdi Hydropower Company Limited (CHL) has announced its 10th and 11th Annual General Meeting (AGM), scheduled for 5th Poush, 2081. It is going to be held in Agrawal Bhawan, Kamalpokhari, Kathmandu, at 9:00 AM.

AGM Agendas:

Endorsement of Financial Reports:

  • Approval of financial reports for 2079/80 and 2080/81 fiscal years.

Auditor’s Report and Financial Statements:

  • Discuss and adopt the auditor’s report, profit and loss statements, financial reports, and cash flow statements.

Appointment of Auditor:

  • Approve the appointment of the auditor for the fiscal year 2081/82.

Facilities of Board of Directors:

  • Review and discuss the facilities provided to the Board of Directors (BoDs).

Authority to Amend Articles of Association:

  • Empower the BoDs to make necessary changes to the Articles of Association and include amendments based on regulatory instructions.

Miscellaneous:

  • Discuss any other matters that may be necessary.

Book Closure Date:

The date of book closure is set for Mangsir 27, 2081. Shareholders whose names are recorded in the company’s books prior to this date will be eligible to attend the AGM and exercise their voting rights.

This AGM provides an excellent opportunity for shareholders to stay updated on the company’s performance, participate in decision-making processes, and align their views with future strategies at CHL.

Suryodaya Womi Laghubitta Proposes DIVEDENT FOR 2081/82

Suryodaya Womi Laghubitta Bittiya Sanstha Limited (SWMF) has announced a proposed 7% dividend for the fiscal year 2080/81, amounting to Rs. 7.30 crores. This decision was made during the 228th board meeting held on Mangsir 4. The dividend is based on the company’s paid-up capital of Rs. 1.04 Arba.

Breakdown of the Proposed Dividend:

  1. 6% Bonus Shares:
    Worth Rs. 6.26 crores, these shares will be distributed to shareholders, increasing their equity in the company.
  2. 1% Cash Dividend:
    Equivalent to Rs. 1.04 crores, this will be provided for tax purposes.

Conditions for Distribution:

The proposed dividend is subject to:

  • Approval by the Nepal Rastra Bank (NRB)
  • Endorsement by the company’s Annual General Meeting (AGM)

Market Perspective:

As of now, SWMF’s Last Traded Price (LTP) stands at Rs. 830.00, reflecting investor sentiment and market valuation.

This announcement underscores the company’s commitment to rewarding its shareholders while adhering to regulatory requirements. Shareholders can look forward to the dividend distribution after the necessary approvals.

WHAT DO YOU MEAN BY GDP

Gross Domestic Product, or GDP, is the total value of all the goods and services that are produced within an economy country in a certain period of time, like a year or quarter. This is one of the most used measures by economists, policy makers, and analysts for measuring the size and health of economies.

Key Elements of GDP:

Components of GDP:

  • Consumption (C): Spending of households on different commodities and services.
  • Investment: The money spent in capital goods, like machinery, infrastructure, and technology.
  • Government Spending (G): Expenditure by the government on services such as education, defense, and healthcare.
  • Net Exports (X – M): A country’s exports minus its imports.

Types of GDP:

  • Nominal GDP: This measures at current market prices, with inflation included.
  • Real GDP: Adjusted for inflation, providing a more accurate reflection of economic growth.
  • Per Capita GDP: The division of GDP by population seems to reflect the average output per person.

Methods of Measuring GDP:

  • Production Method: Summing up the value added in each stage of production.
  • Income Approach: Adding up all incomes earned by the factors of production, like wages, rents, and profits.
  • Expenditure Approach: Adding up spending on all final goods and services.

Importance of GDP:

  • Indicator of Economy: It shows the economic performance of a country.
  • Policy Decisions: Leads the government in making fiscal and monetary policies.
  • International Comparisons: Enables the comparison of economic strength between countries.
  • Investment Insights: Helps investors understand the potential for growth of markets.

Limitations of GDP:

  • Nonmarket Activities: Does not include unpaid work like housekeeping activities and voluntary services.
  • Environmental Impact: Does not take into consideration ecological damages or depletion of natural resources.
  • Income Inequality: It doesn’t account for wealth distribution within a country.
  • Quality of Life: Not all GDP growth is well-being improvement.

In conclusion, while GDP is an important tool to comprehend economic activity, it must be used in comparison with available indicators for a comprehensive picture of economic health and social progress.

TO DO APP IN PYTHON

def display_menu():
    print("\nTo-Do List Menu:")
    print("1. Add task")
    print("2. Remove task")
    print("3. View tasks")
    print("4. Save to file")
    print("5. Exit")

def main():
    to_do_list = []

    while True:
        display_menu()
        choice = input("Enter your choice: ")

        if choice == "1":
            task = input("Enter a task: ")
            to_do_list.append(task)
            print(f"Task '{task}' added.")
        elif choice == "2":
            task = input("Enter the task to remove: ")
            if task in to_do_list:
                to_do_list.remove(task)
                print(f"Task '{task}' removed.")
            else:
                print("Task not found.")
        elif choice == "3":
            print("To-Do List:")
            for idx, task in enumerate(to_do_list, start=1):
                print(f"{idx}. {task}")
        elif choice == "4":
            with open("todo_list.txt", "w") as file:
                for task in to_do_list:
                    file.write(task + "\n")
            print("Tasks saved to 'todo_list.txt'.")
        elif choice == "5":
            print("Exiting program. Goodbye!")
            break
        else:
            print("Invalid choice. Please try again.")

main()
Python

Program To Manage Shopping List In Python

def display_menu():
    print("\nShopping List Menu:")
    print("1. Add item")
    print("2. Remove item")
    print("3. View list")
    print("4. Exit")

def main():
    shopping_list = []
    while True:
        display_menu()
        choice = input("Enter your choice: ")

        if choice == "1":
            item = input("Enter item to add: ")
            shopping_list.append(item)
            print(f"{item} added to the list.")
        elif choice == "2":
            item = input("Enter item to remove: ")
            if item in shopping_list:
                shopping_list.remove(item)
                print(f"{item} removed from the list.")
            else:
                print(f"{item} is not in the list.")
        elif choice == "3":
            print("Shopping List:")
            for item in shopping_list:
                print(f"- {item}")
        elif choice == "4":
            print("Exiting program. Goodbye!")
            break
        else:
            print("Invalid choice. Please try again.")

main()
Python

FUTSAL BOOKING SYSTEM CODE IN HTML CSS AND JAVASCRIPT

<!DOCTYPE html>
<html lang="en">
<head>
    <meta charset="UTF-8">
    <meta name="viewport" content="width=device-width, initial-scale=1.0">
    <title>Advanced Footsal Booking System</title>
    <style>
        /* Basic styling */
        body {
            font-family: Arial, sans-serif;
            background-color: #f0f8ff;
            margin: 0;
            padding: 0;
            display: flex;
            justify-content: center;
            align-items: center;
            min-height: 100vh;
        }
        .container {
            width: 90%;
            max-width: 700px;
            padding: 20px;
            background-color: #ffffff;
            border-radius: 8px;
            box-shadow: 0px 0px 15px rgba(0, 0, 0, 0.1);
        }
        h1, h2 {
            text-align: center;
            color: #333;
        }
        .form-group {
            margin-bottom: 20px;
        }
        label {
            display: block;
            font-weight: bold;
            color: #555;
        }
        input, select, textarea {
            width: 100%;
            padding: 10px;
            margin-top: 5px;
            border: 1px solid #ddd;
            border-radius: 5px;
            box-sizing: border-box;
        }
        button {
            width: 100%;
            padding: 12px;
            background-color: #28a745;
            color: #fff;
            border: none;
            border-radius: 5px;
            font-size: 16px;
            cursor: pointer;
            margin-top: 15px;
        }
        button:hover {
            background-color: #218838;
        }
        .summary, .history, .ratings, .available-slots, .feedback-container {
            display: none;
            margin-top: 20px;
            padding: 15px;
            background-color: #f8f9fa;
            border: 1px solid #ddd;
            border-radius: 5px;
        }
        #ratings input[type="radio"] {
            margin-right: 5px;
        }
        .error-message {
            color: red;
            font-size: 0.9em;
            display: none;
            margin-top: 5px;
        }
        .success-message {
            color: green;
            font-size: 0.9em;
            display: none;
            margin-top: 5px;
        }
        .history-list, .slots-list {
            list-style-type: none;
            padding: 0;
        }
        .history-list li, .slots-list li {
            padding: 8px;
            background-color: #e9ecef;
            margin-bottom: 5px;
            border-radius: 4px;
        }
    </style>
</head>
<body>

<div class="container">
    <!-- Title and Image -->
    <h1>⚽ Advanced Footsal Booking System ⚽</h1>
    
    <!-- Booking Form -->
    <div id="bookingForm">
        <div class="form-group">
            <label for="name">👤 Name:</label>
            <input type="text" id="name" placeholder="Enter your name" required>
            <div class="error-message" id="nameError">Please enter your name.</div>
        </div>
        <div class="form-group">
            <label for="phone">📞 Phone Number:</label>
            <input type="text" id="phone" placeholder="Enter your phone number" required>
            <div class="error-message" id="phoneError">Please enter a valid phone number.</div>
        </div>
        <div class="form-group">
            <label for="date">📅 Booking Date:</label>
            <input type="date" id="date" required>
            <div class="error-message" id="dateError">Please select a valid date.</div>
        </div>
        <div class="form-group">
            <label for="time">🕒 Time Slot:</label>
            <select id="time" required>
                <option value="">Select Time Slot</option>
                <option value="6 AM - 8 AM">6 AM - 8 AM</option>
                <option value="8 AM - 10 AM">8 AM - 10 AM</option>
                <option value="4 PM - 6 PM">4 PM - 6 PM</option>
                <option value="6 PM - 8 PM">6 PM - 8 PM</option>
            </select>
            <div class="error-message" id="timeError">Please select a time slot.</div>
        </div>
        <div class="form-group">
            <label for="players">👥 Number of Players:</label>
            <input type="number" id="players" placeholder="Enter number of players" min="1" required>
            <div class="error-message" id="playersError">Please enter the number of players.</div>
        </div>
        <button onclick="bookFootsal()">📅 Book Now</button>
    </div>

    <!-- Booking Summary -->
    <div id="summary" class="summary">
        <h2>🎉 Booking Confirmation 🎉</h2>
        <p id="bookingDetails"></p>
        <button onclick="downloadSummary()">📄 Download as PDF</button>
        <button onclick="printSummary()">🖨️ Print Confirmation</button>
        <button onclick="showRatingForm()">🌟 Rate Your Experience</button>
    </div>

    <!-- Success Message -->
    <div class="success-message" id="successMessage">Booking successful!</div>

    <!-- Error Message for Double Booking -->
    <div class="error-message" id="bookingError">⚠️ This slot is already booked. Please choose another time or date.</div>

    <!-- Rating and Feedback -->
    <div id="ratings" class="ratings">
        <h2>🌟 Rate Your Booking</h2>
        <label>Rating:</label>
        <div>
            <input type="radio" name="rating" value="1"> 1
            <input type="radio" name="rating" value="2"> 2
            <input type="radio" name="rating" value="3"> 3
            <input type="radio" name="rating" value="4"> 4
            <input type="radio" name="rating" value="5"> 5
        </div>
        <div class="form-group">
            <label for="feedback">💬 Feedback:</label>
            <textarea id="feedback" placeholder="Write your feedback here"></textarea>
        </div>
        <button onclick="submitFeedback()">📥 Submit Feedback</button>
    </div>

    <!-- Booking History -->
    <div id="history" class="history">
        <h2>📋 Booking History</h2>
        <ul id="historyList" class="history-list"></ul>
    </div>

    <!-- Available Slots -->
    <div id="availableSlots" class="available-slots">
        <h2>🕒 Available Slots</h2>
        <ul id="slotsList" class="slots-list"></ul>
    </div>
</div>

<script>
    const bookings = [];
    let uniqueID = 1;

    function bookFootsal() {
        clearErrors();

        const name = document.getElementById("name").value;
        const phone = document.getElementById("phone").value;
        const date = document.getElementById("date").value;
        const time = document.getElementById("time").value;
        const players = document.getElementById("players").value;

        // Validate inputs
        if (!name || !phone || !date || !time || players < 1) {
            showErrors(name, phone, date, time, players);
            return;
        }

        // Check if slot is already booked
        if (isSlotTaken(date, time)) {
            document.getElementById("bookingError").style.display = "block";
            return;
        }

        // Generate unique ID and calculate cost
        const bookingID = `FBS${uniqueID++}`;
        const cost = players * 100;
        const bookingDetails = `
            <strong>Booking ID:</strong> ${bookingID}<br>
            <strong>Name:</strong> ${name}<br>
            <strong>Phone:</strong> ${phone}<br>
            <strong>Date:</strong> ${date}<br>
            <strong>Time Slot:</strong> ${time}<br>
            <strong>Number of Players:</strong> ${players}<br>
            <strong>Total Cost:</strong> NPR ${cost}
        `;

        // Store booking in history
        bookings.push({
            id: bookingID,
            name,
            phone,
            date,
            time,
            players,
            cost,
        });

        document.getElementById("bookingDetails").innerHTML = bookingDetails;
        document.getElementById("summary").style.display = "block";
        document.getElementById("bookingForm").style.display = "none";
        document.getElementById("successMessage").style.display = "block";

        updateHistory();
        setTimeout(() => document.getElementById("successMessage").style.display = "none", 3000);
    }

    function clearErrors() {
        document.querySelectorAll(".error-message").forEach(error => error.style.display = "none");
        document.getElementById("bookingError").style.display = "none";
    }

    function showErrors(name, phone, date, time, players) {
        if (!name) document.getElementById("nameError").style.display = "block";
        if (!phone) document.getElementById("phoneError").style.display = "block";
        if (!date) document.getElementById("dateError").style.display = "block";
        if (!time) document.getElementById("timeError").style.display = "block";
        if (!players) document.getElementById("playersError").style.display = "block";
    }

    function isSlotTaken(date, time) {
        return bookings.some(booking => booking.date === date && booking.time === time);
    }

    function downloadSummary() {
        alert("Downloading summary as PDF...");
    }

    function printSummary() {
        alert("Sending summary to the printer...");
    }

    function updateHistory() {
        const historyList = document.getElementById("historyList");
        historyList.innerHTML = bookings.map(booking => `
            <li>${booking.date} - ${booking.time} (${booking.players} players) - NPR ${booking.cost}</li>
        `).join("");
        document.getElementById("history").style.display = "block";
    }

    function showAvailableSlots() {
        const slotList = ["6 AM - 8 AM", "8 AM - 10 AM", "4 PM - 6 PM", "6 PM - 8 PM"];
        const bookedSlots = bookings.map(booking => `${booking.date}: ${booking.time}`);
        const availableSlots = slotList.filter(slot => !bookedSlots.includes(slot));
        document.getElementById("slots").innerHTML = availableSlots.join("<br>");
        document.getElementById("availableSlots").style.display = "block";
    }

    function showRatingForm() {
        document.getElementById("ratings").style.display = "block";
    }

    function submitFeedback() {
        const feedback = document.getElementById("feedback").value;
        const rating = document.querySelector('input[name="rating"]:checked').value;
        alert(`Thank you for your feedback!\nRating: ${rating} stars\nFeedback: ${feedback}`);
        document.getElementById("ratings").style.display = "none";
    }
</script>

</body>
</html>
HTML

error: Content is protected !!
Scroll to Top
MacroNepal
Verified by MonsterInsights