Step 1: Link bond length to bond order.
A higher bond order means a shorter, tighter bond. So bond length is roughly inversely related to bond order.
Step 2: Find the O-O bond orders.
In $O_2$ the bond order is 2. In $O_3$ the two equal O-O bonds share, giving 1.5 each. In $H_2O_2$ there is a single O-O bond, so bond order 1.
Step 3: Order the lengths.
Smaller bond order means longer bond, so length goes $H_2O_2>O_3>O_2$. This is exactly Statement I, so Statement I is correct.
Step 4: Look at carbon hybridisation in graphite.
In graphite each carbon makes three sigma bonds in a flat sheet, so it is $sp^2$.
Step 5: Look at carbon in pyridine.
Pyridine is an aromatic flat ring like benzene, so each ring carbon is also $sp^2$. So Statement II is correct.
Step 6: Combine.
Both statements are right. \[ \boxed{\text{Both I and II are correct}} \]