Bash Variable To Array Javascript Length Method In C