Input (grade 12): After World War II started, Estonia was occupied by the Soviet Union (USSR) in 1940, and later occupied by Nazi Germany from 1941 - 44.
Output (grade 8): It became independent in 1918 after World War I, but after World War II it was ruled by the USSR.