I've created a poker deck for a video poker assignment, and it seems that every card is a King of Spades. I have an array of Card(s, v) obejcts theDeck[52]. I'm assuming that every card turns out to be Card(4, 13). Here's my Deck constructor:

import java.util.Random;
public class Deck {
 
	private Card[] theDeck; 
	private int top; 
	// add more instance variables if needed
 
	public Deck(){
		theDeck = new Card[52];
		for(int s = 1; s <= 4; s++)
		{
			for (int v = 1; v <= 13; v++)
			{
				for (int i = 0; i < theDeck.length; i++)
				{
 
					theDeck[i] = new Card(s,v);
				}
			}
		}	
	}

I don't see anything wrong with it. It might be that the problem is somewhere else; I just wanna make sure it's not in the construction of the deck. Thanks.

Here's also the Card constructor from the Card class:

 
public class Card implements Comparable<Card>
{
 
	private int suit; 
	private int value; 
 
	public Card(int s, int v)
	{ //constructor of an object Card
		suit = s;
		value = v;
		//make a card with suit s and value v
	}


--- Update ---

I got it -- the last loop was overriding the entire deck.