Computer Programming 2nd Part By Tamim Shahriar Subeen May 2026

file = open("example.txt", "w") file.write("Hello, world!") file.close() In this example, we open a file called example.txt in write mode ( "w" ), write the string "Hello, world!" to it, and close the file.

For example:

”`python colors = (“red”, “green”, “blue”) print(colors[0]) # Output: red

For example:

Premium?
With or without frames?
Number of Sides:
Size(In Inches):