Website Summary Files Commits Branches @commit @diff @stats
path: root / Week02 / Exercise05 / warehouse.cpp
blob: ea968ab1f05a0ab5797fd4ed6ab7b857cac94ba6 (plain) (blame)
1
2
3
4
5
6
7
8
9
#include "warehouse.h"

bool Warehouse::storePackage(const Package& p) {
	if (storedPackages >= packageCapacity)
		return false;

	packages[storedPackages++] = p;
	return true;
}