79518098

Date: 2025-03-18 16:31:31
Score: 1
Natty:
Report link

use this:

function foo {
  typeset x=2  # Makes x local to the function
}

x=1
foo
echo $x  # This will print 1
Reasons:
  • Low length (1):
  • Has code block (-0.5):
  • Low reputation (0.5):
Posted by: Martin