I'm really new to this guys so go easy on me, I'm making a card dealing simulation and want to know a way of assigning numeric values to my cards "ranks", which are currently string types, here's what I have so far;
import java.util.Scanner;
import java.util.Random;
class card_deck{
public static void main(String args[]){
Scanner in = new Scanner(System.in);
String[] suit = {"Spades", "Hearts", "Clubs", "Diamonds"};
Random random = new Random();
int selectS = random.nextInt(suit.length);
String[] rank = {"Ace", "2", "3", "4", "5", "6", "7", "8", "9", "10", "Jack", "Queen", "King"};
int selectR = random.nextInt(rank.length);
System.out.println(rank[selectR] + " of " + suit[selectS]);
}
}