// Arup Guha
// 9/30/2015
// Solution to 2003 UCF HS Contest Problem: The Shawshank Transaction (Overdraft)

import java.util.*;

public class overdraft {

	public static void main(String[] args) {

		Scanner stdin = new Scanner(System.in);
		int checking = stdin.nextInt();
		int savings = stdin.nextInt();
		int n = stdin.nextInt();

		// Process all cases.
		while (n != 0) {

			boolean overdraft = false;

			// Process transactions.
			for (int i=0; i<n; i++) {
				int subtract = stdin.nextInt();

				// Overdraft case.
				if (subtract > checking) {
					subtract -= checking;
					checking = 0;
					overdraft = true;
					savings -= subtract;
				}

				// Isn't it much nicer when you don't bounce checks!
				else
					checking -= subtract;
			}

			// Output stuff for this case.
			System.out.println(checking);
			System.out.println(savings);
			if (overdraft) System.out.println("OVERDRAFT");
			else			System.out.println("CLEAR");
			System.out.println();

			// Get next case.
			checking = stdin.nextInt();
			savings = stdin.nextInt();
			n = stdin.nextInt();
		}
	}
}