Amazon Interview Question

Implement a paint or fill function