How do i combine two Arduino sketches?

Hello,
I am a newbie, I’m in trouble now. I found two codes on the internet, but do not know how to combine them into one. I hope there is a help. Thank you

Respect!

i2c_LCDSmartie_Project_V1_1.ino (13.9 KB)

Control_Relay_with_IR.ino (587 Bytes)

This Simple Merge Demo may be useful.

...R

Then there is this:- http://www.thebox.myzen.co.uk/Tutorial/Merging_Code.html