Ecosyste.ms: Awesome
An open API service indexing awesome lists of open source software.
https://github.com/scribu/train-tickets.rs
Rust programming exercise
https://github.com/scribu/train-tickets.rs
Last synced: about 6 hours ago
JSON representation
Rust programming exercise
- Host: GitHub
- URL: https://github.com/scribu/train-tickets.rs
- Owner: scribu
- Created: 2015-02-01T23:37:22.000Z (almost 10 years ago)
- Default Branch: master
- Last Pushed: 2015-02-01T23:40:20.000Z (almost 10 years ago)
- Last Synced: 2024-10-18T15:53:28.168Z (21 days ago)
- Language: Rust
- Size: 121 KB
- Stars: 1
- Watchers: 1
- Forks: 0
- Open Issues: 0
-
Metadata Files:
- Readme: README.md
Awesome Lists containing this project
README
# Train Tickets
Problem: Implement an algorithm for allocating seats for train passengers. Each coach has a number of compartments; each compartment has a fixed number of seats.
A person buying multiple seats (for their family, or for a group of friends etc.) should have them in the same compartment or in as few compartments as possible.
Developed using rustc 0.13.0-nightly (0a5e7f359 2014-11-03 23:16:55 +0000).
### Running interactively
```
cargo run
```### Running tests
```
cargo test
```