title: Working on an assignment, console not displaying intended result
body: <p>Disclaimer: I'm very new to JS</p>
  
  <p>Hi all,</p>
  
  <p>I'm working on a card game for the web browser and in the console I'm supposed to get the following:</p>
  
  <pre><code>// User flipped queen
  // images/queen-of-hearts.png
  // hearts
  // User flipped king
  // images/king-of-hearts.png
  // hearts
  </code></pre>
  
  <p>The only message I'm seeing in the console is "up and running" (see the code below).</p>
  
  <p>I'm also supposed to get the following pop up:</p>
  
  <blockquote>
    <p>"This page says: Sorry, try again."</p>
  </blockquote>
  
  <p>After following the (pretty vague) posted instructions, browsing my course group's Slack posts, and trial and error, I haven't gotten anywhere. So I thought I'd post my code to stackoverflow to see if anyone spots something I missed or if something's in the wrong place.</p>
  
  <p>Thanks! Here's the code:</p>
  
  <pre><code>console.log('up and running');
  
  var cards = [
  
  {
  rank: 'queen',
  suit: 'hearts',
  cardImage: 'images/queen-of-hearts.png',
  },
  
  {
  rank: 'queen',
  suit: 'diamonds',
  cardImage: 'images/queen-of-diamonds.png',
  },
  
  {
  rank: 'king',
  suit: 'hearts',
  cardImage: 'images/king-of-hearts.png',
  },
  
  {
  rank: 'king',
  suit: 'diamonds',
  cardImage: 'images/king-of-diamonds.png'
  }
  
  ];
  
  
  
  var cardsInPlay = [];
  
  var flipCard = function() {
      console.log("User flipped " + cards[cardId].rank);
  
      console.log(cards[cardId].cardImage);
      console.log(cards[cardId].suit);
  
      cardsInPlay.push(cards[cardId].rank);
  
  }
  
  
  var checkForMatch = function() {
      if (cardsInPlay.length === 2) {
          if (cardsInPlay[0] === cardsInPlay[1]) {
                  alert('You found a match!');
              } else {
                  alert('Sorry, try again.');
      };  
  };
  };
  
  checkForMatch();
  </code></pre>