Welcome to my Website!
This is a paragraph! Here's how you make a link: Neocities.
Here's how you can make bold and italic text.
Here's how you can add an image:
Here's how to make a list:
- print("Welcome to ALEXNET!")
def show_menu():
print("1. Access Files")
print("2. Use Calculator")
print("3. Settings")
print("4. Display Message")
print("5. Exit")
def access_files():
file_names = ["taxmomenyz.txt", "diary.txt", "shadow.txt"]
print("Available files:")
for i, file in enumerate(file_names, start=1):
print(f"{i}. {file}")
choice = int(input("Select a file (1-3): "))
if 1 <= choice <= 3:
file_index = choice - 1
file_name = file_names[file_index]
with open(file_name, "r") as file:
content = file.read()
print(f"\n{file_name} A:")
print(content)
while True:
option = input("\n1. Open\n2. Edit\n3. Go back\nChoose an option: ")
if option == "1":
print(f"\n{file_name} Contents:")
print(content)
elif option == "2":
new_content = input("Enter new content:\n")
with open(file_name, "w") as file:
file.write(new_content)
print(f"{file_name} has been updated.")
elif option == "3":
break
else:
print("Invalid option. Try again.")
def use_calculator():
while True:
print("\nCalculator Menu:")
print("1. Add")
print("2. Subtract")
print("3. Multiply")
print("4. Divide")
print("5. Go back")
choice = input("Choose an option (1-5): ")
if choice == "1":
num1 = float(input("Enter first number: "))
num2 = float(input("Enter second number: "))
result = num1 + num2
print(f"Result: {result}")
elif choice == "2":
num1 = float(input("Enter first number: "))
num2 = float(input("Enter second number: "))
result = num1 - num2
print(f"Result: {result}")
elif choice == "3":
num1 = float(input("Enter first number: "))
num2 = float(input("Enter second number: "))
result = num1 * num2
print(f"Result: {result}")
elif choice == "4":
num1 = float(input("Enter dividend: "))
num2 = float(input("Enter divisor: "))
result = num1 / num2
print(f"Result: {result}")
elif choice == "5":
break
else:
print("Invalid option. Try again.")
def settings():
print("\nSettings:")
print("This is a simple text-based operating system.")
input("Press Enter to continue...")
def display_message():
print("\nRafael is cool!")
def main():
while True:
show_menu()
choice = input("Choose an option (1-5): ")
if choice == "1":
access_files()
elif choice == "2":
use_calculator()
elif choice == "3":
settings()
elif choice == "4":
display_message()
elif choice == "5":
print("Exiting the program.")
break
else:
print("Invalid option. Try again.")
if __name__ == "__main__":
main()
- Second thing
- Third thing
To learn more HTML/CSS, check out these tutorials!