CPTTRN1 - Character Patterns (Act 1)
Using two characters: . (dot) and * (asterisk) print a chessboard-like pattern. The first character printed should be * (asterisk).
You are given t < 100 - the number of test cases and for each of the test cases two positive integers: l - the number of lines and c - the number of columns in the pattern (l, c < 100).
For each of the test cases output the requested pattern (please have a look at the example). Use one line break in between successive patterns.
Input: 3 3 1 4 4 2 5 Output: * . * *.*. .*.* *.*. .*.* *.*.* .*.*.
15461368 :- what is fault in my code??? i can't understand.
the conditions are not mentions properly...
2nd output 4 4 is not correct output as per other pattern is concerned.In 2nd line the output pattern should be first * not . after . of 1st line