new to the arduino

i have just bought a arduino uno R3 and i dont really understand how it all works

The IDE comes with a whole load of examples. Try working through a few, then try modifying them to figure out how they work.