A simple C# console application that processes command-line instructions like PLACE_ORDER
and TOTAL_COST
.
dotnet restore
dotnet build
Pass commands as arguments inside quotes:
dotnet run --project App -- "PLACE_ORDER 101 Apple 5" "TOTAL_COST 101"
✅ Each string represents a command and its arguments.
Unit tests are located in the App.Tests
project.
dotnet test
App.sln
├── App/ # Console app source code
│ └── Program.cs
│
├── App.Tests/ # xUnit test project
│ └── UnitTest1.cs
│
└── README.md # This file
PLACE_ORDER 101 Apple 5
TOTAL_COST 101
- Commands are parsed in
Program.cs → Handle(string input)
. - Extend the
Handle
method to implement actual business logic. - State can be maintained via static dictionaries or service classes.