What would be the difference between two of them? Is the first one used at all? My teacher says I should prefer the last one to be understood and to avoid confusion.
中饭 and 午饭 both refer to
lunch. But as the answer mentioned, they are different in the environment you use it.
午饭 is more formal than
午饭 can be used both in spoken and written Chinese. But
中饭 is used in spoken Chinese and mostly in dialect in southern China. As I come from southern Jiangsu(江苏) province, we never say
午饭 in our conversation.
You can see more here: