













Study with the several resources on Docsity
Earn points by helping other students or get them with a premium plan
This page cannot be seen from the preview
Don't miss anything!














[email protected] www.pp.rhul.ac.uk/~cowan/stat_course.html
st
st
th
usr/ bin/ home/ sys/ tmp/ ... smith/ jones/ jackson/ ... WWW/ code/ thesis/ ...
pwd Show present working directory ls List files in present working directory ls -la List files of present working directory with details man ls Show manual page for ls. Works for all commands. man -k keyword Searches man pages for info on “keyword”. cd Change present working directory to home directory. mkdir foo Create subdirectory foo cd foo Change to subdirectory foo (go down in tree) cd .. Go up one directory in tree rmdir foo Remove subdirectory foo (must be empty) emacs foo & Edit file foo with emacs (& to run in background) more foo Display file foo (space for next page) less foo Similar to more foo , but able to back up ( q to quit) rm foo Delete file foo
cp foo bar Copy file foo to file bar, e.g., cp ~smith/ foo ./ copies Smith’s file foo to my current directory mv foo bar Rename file foo to bar lpr foo Print file foo. Use -P to specify print queue, e.g., lpr -Plj1 foo (site dependent). ps Show existing processes kill 345 Kill process 345 ( kill -9 as last resort) ./ foo Run executable program foo in current directory ctrl -c Terminate currently executing program chmod ug+x foo Change access mode so user and group have privilege to execute foo (Check with ls -la )
// My first C++ program #include using namespace std; int main(){ cout << "Hello World!" << endl; return 0; }
g++ -o HelloWorld HelloWorld.cc Invokes compiler (gcc) name of output file source code
Hello World! ← computer shows this
**#!/bin/sh
g++ -o HelloWorld HelloWorld.cc Bonjour.cc GruessGott.cc YoDude.cc**
*These lines here are comments / / and so are these /
int main(){ // body of program goes here return 0; }
cout << "Hello World!" << endl;