var n; do { write("Enter number of lines: "); n = read(); } while (n<=0 || isNaN(n)); for (var i=1; i<=n; i++) { for (var j=1; j<=n*2; j++) { if ((i%2==1 && j%2==1) || (i%2==0 && j%2==0)) { write("1"); } else { write("0"); } } write("\n"); }
(
)
{
}
[
]
"
;
=
+
-
*
!
/
%
&
|