ngn APL, 7 bytes
{∇⍞←⍞}1
ngn APL only supports linewise input and has no actual looping constructs, so this recursive function is as good as it gets. It prints null bytes, but only if they do not occur on the last line.
How it works
{ } Define a function.
⍞←⍞ Read and print a line.
∇ Call the function again.
1 Call the function with dummy input.
⍞ exits automatically on EOF.
ngn APL, 7 bytes
{∇⍞←⍞}1
ngn APL only supports linewise input and has no actual looping constructs, so this recursive function is as good as it gets.
How it works
{ } Define a function.
⍞←⍞ Read and print a line.
∇ Call the function again.
1 Call the function with dummy input.
⍞ exits automatically on EOF.
ngn APL, 7 bytes
{∇⍞←⍞}1
ngn APL only supports linewise input and has no actual looping constructs, so this recursive function is as good as it gets. It prints null bytes, but only if they do not occur on the last line.
How it works
{ } Define a function.
⍞←⍞ Read and print a line.
∇ Call the function again.
1 Call the function with dummy input.
⍞ exits automatically on EOF.
ngn APL, 7 bytes
{∇⍞←⍞}1
ngn APL only supports linewise input and has no actual looping constructs, so this recursive function is as good as it gets.
How it works
{ } Define a function.
⍞←⍞ Read and print a line.
∇ Call the function again.
1 Call the function with dummy input.
⍞ exits automatically on EOF.