Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- /*
- * To change this template, choose Tools | Templates
- * and open the template in the editor.
- */
- package javaapplication1;
- /**
- *
- * @author rlm11264
- */
- public class Main {
- /**
- * @param args the command line arguments
- */
- public static void main(String[] args) throws Exception
- {
- String card[][] = new String[4][10];
- int x,y;
- for (y=0;y<10;y++)
- {
- for (x=0;x<4;x++)
- {
- card[x][y]="X";
- }
- }
- System.out.printf("%5s%10s%10s%10s%10s","Rank","Clubs","Diamonds","Spades","Hearts");
- System.out.println();
- for (y=0;y<10;y++)
- {
- System.out.printf("%3d", y+1);
- for (x=0;x<4;x++)
- {
- System.out.printf("%10s", card[x][y]);
- }
- System.out.println();
- }
- }
- }
Add Comment
Please, Sign In to add comment