We study a variation of the minority game. There are N agents. Each has to choose between one of two alternatives everyday, and there is reward to each member of the smaller group. The agents cannot communicate with each other, but try to guess the choice others will make, based only the past history of number of people choosing the two alternatives. We describe a simple probabilistic strategy using which the agents acting independently, can still maximize the average number of people benefitting every day. The strategy leads to a very efficient utilization of resources, and the average deviation from the maximum possible can be made of order $(N^{epsilon})$, for any $epsilon >0$. We also show that a single agent does not expect to gain by not following the strategy.