For the first script, you do not want to use 'ls -d'. Please see the man page for ls (man ls). The -d flag to ls will list a directory itself, without recursing underneath it. With the -d flag, you actually need to pass the directory, or directories as arguments.
In order to get a listing of the files within a directory, just execute 'ls /directory_name' without any arguments at all. Some you may want to consider though are '-a' which shows hidden files, or '-l' which produces more detailed information for the files.
The redirection for the script, >>, will append data to the bottom of whatever file is specified. Chances are you would rather overwrite anything in the current file, if it exists. You can do this by just using >. So, the first script should look something like this:
ls > /tmp/file.txt
Note, adding "/tmp" (or any directory that is writeable to you) is a good idea. Otherwise, your script will try to write the output file to the /bin directory itself, which you should not have write access to, and will thus fail.
For the second script, cd and ls should not be on the same line. To copy files from one directory to another in shell, you would want to use something like:
#define A 3// name a constant
long int booking_ID ; ...