FÖRHELVETE

package iDick;

import java.util.Scanner;

public class Income {
public static void main(String[] args){
taxes();
actionChooser();
}
public static void taxes() {
// sätt ihop dessa med andra klasser
int happiness = 100;
int cash = 100;
int taxes = 25;

System.out.println("Taxes are currently: " + taxes);
System.out.print("Enter new taxes: ");

Scanner userinput = new Scanner(System.in);
int newTaxes = userinput.nextInt();

if(newTaxes > taxes) {
System.out.println("You made taxes higher. People of your town will not
be happy..");
happiness = ( happiness - (newTaxes / 2) );
cash = (cash + newTaxes);
System.out.println("Happiness is now: " + happiness + " and cashflow: "
+ cash);
}

if(newTaxes < taxes) {
System.out.println("You lowered the taxes. People will be happier.");
happiness = ( happiness + (newTaxes / 2) );
cash = (cash - newTaxes);
System.out.println("Happiness is now: " + happiness + " and cashflow: "
+ cash);
}
}
public static void actionChooser() {
System.out.println("Would you like to enter new taxes again?");
String yes = "yes";
String no = "no";
Scanner userinput2 = new Scanner(System.in);
String yesno = userinput2.next();
System.out.println("you entered " + yesno);
if(yesno == yes) {
System.out.println("you entered " + yesno + " but it does not matter..
");
}
}
}