Quiz: How do you print the value of the $PWD shell variable in #Linux or #Unix? Choose one answer only.
awk 'BEGIN {print ENVIRON["PWD"]}'
3%
cat <<<"$PWD"
1.4%
echo "$PWD"
92.8%
printf "%s\n" "$PWD"
2.8%
Poll ended at .
@nixCraft Usually I just do
f=$(mktemp) ; printf '#include <stdio.h>\n#include <stdlib.h>\nint main() { printf("%%s\\n", getenv("PWD")); }' > $f.c ; cc $f.c ; ./a.out