Bosch interview question

Given a problem, design a program that solves it with O(n) complexity.