am writing a program that plays rock paper scissor. The user will enter choice manually (rock is1, paper is 2, and scissors is 3) and the computer will chose one at random without letting the user know. The game will run as many times as the player wants. I can use the following: wihile loop, do while loop, if and if else, random.math, int, double, println etc. ( i cant use char, boolean, string and printf). Since I dont have java at home and I have to submit this to my teacher, Plz help me below: ( I want a 100! Plz Help:)). {also my first time writing a program}. Plz give a lot of improvements, I was home schooled and just started a real school, I really want to impress my teacher. THNX:) I know i have a lot of errors:(
Also, output the scores, I have no idea how to do that and this all is due tomoorrow!!
import java.util.scanner;
Public Class Game;
{
Public Class void main (String[]args)
{
int 1 = rock;
int 2 = paper;
int 3 = scissors;
Scanner scan = new scanner (system.in);
System.out.println("Choose 1 for rock, 2 for paper; 3 for scissors");
int choice = scan.nextInt();
int computer = Math.random();
computer = 3 * Math.random;
do
{
while;
if (computer = 1 && player = 2 || computer = 2 && player = 3 || computer = 3 && player = 1)
System.out.println("You win!!");
if ( player = 1 && computer = 2 || [player = 2 && computer = 3 || player = 3 && computer = 1)
System.out.println("You Lose!!");
esle if (computer = player)
System.out.println ("Tryagain!");
}
}