As far as I know, degree of Unsaturation actually differs with the functional group.
Weightage of an element = Valency (in standard state) - 2
For,
Carbon = 4-2 = 2
Hydrogen = 1-2 = -1
Oxygen = 2-2 = 0
Nitrogen = 3-2 = 1
And Degree of Unsaturation= (sum of product (of weightage and number of corresponding element in formula)) +2)/2
For example,
CH3OH = (2*1+4*(-1)+0*1+2)/2 = (2-4+2)/2 = 0 (Indicates no double bond or ring)
CH3CHO = (2*2+4*(-1)+0+2)/2 = (4-4+2)/2 = 1 (Indicates one double bond or ring [and we see there is a double bond in the structure...A ring structure is also possible for the same formula (epoxide)])
CH3CONH2 = (2*2+5*(-1)+0+1+2)/2 = (4-5+1+2)/2 = 1 (Again a double bond and a ring is possible)..
Double bond is in amide itself. You can also try aldoxime.
For ring you can again try an epoxide.
Hope this is clear.