Skip to content

Latest commit

 

History

History
28 lines (23 loc) · 1003 Bytes

File metadata and controls

28 lines (23 loc) · 1003 Bytes

Memory Game – Flipping Tiles

A straightforward Memory Game where you flip tiles to find matching pairs.

Abstract

• Java-based mind game implemented with Swing.
• An even number of tiles is laid out in a grid. Each color/number/label appears on two tiles.
• Flip two tiles at a time. If they match, they stay revealed; if not, they reset.
• This game is designed to exercise and improve memory.

Technologies Required

• Java 8 or higher
• Java Swing: for GUI components
• Java OOP concepts
• ArrayList: to store tile values and shuffle them for random placement

Instructions

  1. Compile and run the code:
    javac com/example/memorygame/MemoryGame.java
    java com.example.memorygame.MemoryGame
  2. A 4×4 grid with 16 tiles appears. Click on two tiles to flip them:
    • If they match, they remain turned over.
    • If not, they flip back after a short delay.
  3. Keep matching until all tiles are revealed.

Enjoy testing your memory!