{}

Build your resume with HTML & CSS and win $100

Get featured on Programiz PRO and the Wall of Inspiration.

Build your resume with HTML & CSS and win $100

Join Challenge →
Join Challenge →

Build your resume with HTML & CSS and win $100

Get featured on Programiz PRO and the Wall of Inspiration.

Build your resume with HTML & CSS and win $100

Join Challenge →
Join Challenge →
run-icon
main.py
import random print("Hello World") def function(input): print(input) function("this is a string") list=[] list.append("this is the first odject in my list") list.append("this is the second odject in my list") print(list[0]) list.pop(0) print(list) list=[] list.append('item1') list.append('item2') list.append('item3') for item in list: print(item) for i in range(5): print(i) if(1==1): print("1 is equal to 2") else: print("1 is equal to 3") board = [['.', '.', '.'] ,['.', '.', '.'], ['.', '.', '.']] print(board) board[0][0] def print(board): for row_index in range(3): print(board[row_index]) def get_more(board): move_row=int(input("Enter in the row of your move")) move_col=int(input("enter in the column of your move:")) board[move_row][move_col]='x' print_board(board) get_move(board) print_board(board) def get_robot_move(board): more_row=random.randint(0,2) more_col=random.randint(0,2) board[move_row][move_col]='o' print_board(board) print() get_robot_move(board) print_board(board) def get_robot_move(board): move_row = random.randint(0, 2) move_col = random.randint(0, 2) while(board[more_row][more_col] != '.'): more_row =random.randint(0, 2) move_col= random.randint(0, 2) board[move_row][move_col] ='0'
Output