The correct order of basicity of the following amines
I: 2-phenylethanamine (); II: aniline; III: 4-methylaniline; IV: 4-nitroaniline
is

From the KVPY 2019 · Streams SB/SX paper. Try it, check your answer, then read the worked solution below.
The correct order of basicity of the following amines
I: 2-phenylethanamine (); II: aniline; III: 4-methylaniline; IV: 4-nitroaniline
is

Try it yourself first, then check your working against this.
Worked solution
In I the lone pair is on an aliphatic nitrogen, not delocalized into the ring: most basic. In the anilines the lone pair is delocalized into the ring. A para-methyl (electron-donating) makes III more basic than aniline, and a para-nitro (strongly withdrawing) makes IV least basic. So I > III > II > IV.
(B)
Concepts used: basicity of amines, substituent effects
Every past question tagged to the same part of the syllabus, with solutions.
All KVPY questions on General Organic Chemistry · All KVPY questions on Amines and Nitrogen Compounds
Past questions on the same topic (Acidity and basicity), each with a worked solution.
Timed, in the real format, and marked the moment you submit.