UVa 637: decrease and increase numbers