Basic in memory database
Based on the Thumbtack exercise: https://www.thumbtack.com/challenges/simple-database
To generate the class files:
cd app/src/main/java
javac com/johan/inmemorydatabase/database/MemoryDatabase.java
To execute the code:
cd app/src/main/java
java com/johan/inmemorydatabase/database/MemoryDatabase < ../res/raw/test_input2.txt
or
java com/johan/inmemorydatabase/database/MemoryDatabase < ../res/raw/test_input1.txt
You can also enter the commands manually:
java com/johan/inmemorydatabase/database/MemoryDatabase
SET a 10
GET a
END
Or you can just use the app, test with the input files or with the custom input.