The console height & width is controlled by this: https://code.kx.com/q/basics/syscmds/#c-console-size
However, if you need to escape those boundaries without modifying the settings, you can do something like
q)\c 10 30
q)til 20
0 1 2 3 4 5 6 7 8 9 10 11 1..
q)
q)-1" "sv string til 20;
0 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19
q)
q)// or
q)
q)-1 .Q.s2 enlist til 20;
0 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19
.Q.s2
can be used for other structures but bear in mind, like other ‘deeper’ .Q functions, .Q.s2 is undocumented and could be subject to change
q)t:flip (20#`abcd)!2?/:20#10
q)t
abcd abcd abcd abcd abcd ab..
---------------------------..
6 3 8 8 8 4 ..
1 2 2 5 7 1 ..
q)
q)-1 .Q.s2 t;
abcd abcd abcd abcd abcd abcd abcd abcd abcd abcd abcd abcd abcd abcd abcd abcd abcd abcd abcd abcd
---------------------------------------------------------------------------------------------------
6 3 8 8 8 4 9 9 3 9 5 0 9 6 5 9 7 3 9 8
1 2 2 5 7 1 6 4 0 2 8 1 5 5 4 1 2 4 4 3
CLICK HERE to find out more related problems solutions.