package m3;
import java.util.Scanner;
public class demo1 {
public static void main(String[] args) {
int year;
Scanner input = new Scanner(System.in);
System.out.print("请输入您的出生年份:");
year = input.nextInt();
if(year > 0) {
if(year % 12 == 4) {
System.out.print("您的属相为鼠");
}
else if(year % 12 == 5) {
System.out.print("您的属相为牛");
}
else if (year % 12 == 6) {
System.out.print("您的属相为虎");}
else if (year % 12 == 7) {
System.out.print("您的属相为兔");}
else if(year % 12 == 8) {
System.out.print("您的属相为龙");
}
else if(year % 12 == 9) {
System.out.print("您的属相为蛇");
}
else if(year % 12 == 10) {
System.out.print("您的属相为马");
}
else if(year % 12 == 11) {
System.out.print("您的属相为羊");
}
else if(year % 12 == 0) {
System.out.print("您的属相为猴");
}
else if(year % 12 == 1) {
System.out.print("您的属相为鸡");
}
else if(year % 12 == 2) {
System.out.print("您的属相为狗");
}
else if(year % 12 == 3) {
System.out.print("您的属相为猪");
}
}
else {
System.out.print("请输入正确的年份");
}
}
}