The King's Ups and Downs

Problem Number: 
6 177
Type of Problem: 
Problem Category: 
Input: 
0
0
0
Critical Input: 
Random Input: 
Problem Id: 
6177