Jump to content

Terminal control/Dimensions: Difference between revisions

Changed the program to store the wisth and height in variables as required by the task.
(Added Arturo implementation)
(Changed the program to store the wisth and height in variables as required by the task.)
Line 507:
<lang nim>import terminal
 
echo "Terminallet (width:, "height) &= $terminalWidthterminalSize()
 
echo "Terminal height: " & $terminalHeight()
echo "Terminal width: ", width
</lang>
echo "Terminal height: ", & $terminalHeight()height</lang>
 
{{out}}
<pre>Terminal width: 80
Terminal height: 24</pre>
 
=={{header|OCaml}}==
Anonymous user
Cookies help us deliver our services. By using our services, you agree to our use of cookies.