포커 패 (Poker Hands-JAVA) 자바 게임
본 자료는 미리보기를 지원하지 않습니다.
닫기
  • 1
  • 2
  • 3
  • 4
  • 5
  • 6
  • 7
해당 자료는 2페이지 까지만 미리보기를 제공합니다.
2페이지 이후부터 다운로드 후 확인할 수 있습니다.

소개글

포커 패 (Poker Hands-JAVA) 자바 게임에 대한 보고서 자료입니다.

목차

[.settings]
  org.eclipse.jdt.core.prefs
[bin]
  poker.txt
  poker_hannds.class
[src]
  poker.txt
  poker_hannds.java
.classpath
.project




77.1KB
파일 7, 폴더 3

본문내용

public static int p1Check(){
        int s0 = Integer.parseInt(p1[0].substring(0,2));
        int s1 = Integer.parseInt(p1[1].substring(0,2));
        int s2 = Integer.parseInt(p1[2].substring(0,2));
        int s3 = Integer.parseInt(p1[3].substring(0,2));
        int s4 = Integer.parseInt(p1[4].substring(0,2));
        char c0 = p1[0].charAt(2);
        char c1 = p1[1].charAt(2);
        char c2 = p1[2].charAt(2);
        char c3 = p1[3].charAt(2);
        char c4 = p1[4].charAt(2);
        
        if(s0==10&&s1==11&&s2==12&&s3==13&&s4==14){//Royal Flush
            if(c0==c1&&c1==c2&&c2==c3&&c3==c4){
                poker1=\"Royal Flush\";
                return 10;
            }
        }
        if(c0==c1&&c1==c2&&c2==c3&&c3==c4){//Straight Flush
            if((s0+s4)/2==s2&&(s4-s0)==4&&(s1-s0)==(s4-s3)){
                poker1=\"Straight Flush\";
                return 9;
            }
        }
        for(int i=0; i<5; i++){//Four of a Kind
            int fCout=0;
            for(int j=0; j<5; j++){
                if(i!=j && Integer.parseInt(p1[i].substring(0, 2)) == Integer.parseInt(p1[j].substring(0, 2))){
                    fCout++;
                    if(fCout == 3){
                        poker1=\"Four of a Kind\";
                        return 8;
                    }
                }
            }
        }
  • 가격3,000
  • 페이지수7페이지
  • 등록일2015.03.28
  • 저작시기2014.6
  • 파일형식압축파일(zip)
  • 자료번호#962448
본 자료는 최근 2주간 다운받은 회원이 없습니다.
청소해
다운로드 장바구니