注册一亩三分地论坛,查看更多干货!
您需要 登录 才可以下载或查看附件。没有帐号?注册账号 
x
Cisco OA
第一题,write an algorithm to print a chessboard pattern("B" for black squres, "W" for white squares).
input:
the input consits of an interger-inputNum, representing the size of the chessboard(N).
output:
print N lines of N space-separated characters"B" or "W" where each line corresponds to one row of the board.
constraints
0< N < 1000
Examnext M lines consist of N space-separated integers representing the elements in each cell of the matrix.
Output
Print an integer representing the last cell Lucy would hop onto after following the given instructions.
Example
Input:
3 3
29 8 37
15 41 3
1 10 14
Output:
41
90分钟三道题。 |