I'm recoding the Unix command ls, im using multiple system functions including but not limited to , , functions etc. I have all the information I need and have already taken big strides. However, I need help with formatting the output.
when you run the command ls -l and the output is formatted so all columns are the right size regardless of the length of said files names.
I would like to know how to format my output in the same manner as ls, with regard to columns (Just a general idea not actual code). How do I do this?
printffunctions.lscommand - read up about opendir, readdir etc. and use them instead