In: Computer Science
Write a C++ app to read both files, store them into parallel vectors, sort the list of people in alphabetical order, display the new sorted list of names with their corresponding descriptions. Use the Bubble Sort strategy to rearrange the vector(s).
File 1:
Marilyn Monroe
Abraham Lincoln
Nelson Mandela
John F. Kennedy
Martin Luther King
Queen Elizabeth II
Winston Churchill
Donald Trump
Bill Gates
Muhammad Ali
Mahatma Gandhi
Margaret Thatcher
Mother Teresa
Christopher Columbus
Charles Darwin
Elvis Presley
Albert Einstein
Paul McCartney
Queen Victoria
Pope Francis
Jawaharlal Nehru
Leonardo da Vinci
Vincent Van Gogh
Franklin D. Roosevelt
Pope John Paul II
Thomas Edison
Rosa Parks
Lyndon Johnson
Ludwig Beethoven
Oprah Winfrey
Indira Gandhi
Eva Peron
Benazir Bhutto
George Orwell
Desmond Tutu
Dalai Lama
Walt Disney
Neil Armstrong
Peter Sellers
Barack Obama
Malcolm X
J.K.Rowling
Richard Branson
Pele
Angelina Jolie
Jesse Owens
John Lennon
Henry Ford
Haile Selassie
Joseph Stalin
Lord Baden Powell
Michael Jordon
George Bush Jnr
Vladimir Lenin
Ingrid Bergman
Fidel Castro
Leo Tolstoy
Greta Thunberg
Pablo Picasso
Oscar Wilde
Coco Chanel
Charles de Gaulle
Amelia Earhart
John M Keynes
Louis Pasteur
Mikhail Gorbachev
Plato
Adolf Hitler
Sting
Mary Magdalene
Alfred Hitchcock
Michael Jackson
Madonna
Mata Hari
Cleopatra
Grace Kelly
Steve Jobs
Ronald Reagan
Lionel Messi
Babe Ruth
Bob Geldof
Leon Trotsky
Roger Federer
Sigmund Freud
Woodrow Wilson
Mao Zedong
Katherine Hepburn
Audrey Hepburn
David Beckham
Tiger Woods
Usain Bolt
Carl Lewis
Prince Charles
Jacqueline Kennedy Onassis
C.S. Lewis
Billie Holiday
J.R.R. Tolkien
Billie Jean King
Anne Frank
Simon Bolivar
File 2:
(1926 - 1962) American actress, singer, model
(1809 - 1865) US President during American civil war
(1918 - 2013) South African President anti-apartheid
campaigner
(1917 - 1963) US President 1961 - 1963
(1929 - 1968) American civil rights campaigner
(1926 - ) British monarch since 1954
(1874 - 1965) British Prime Minister during WWII
(1946 - ) Businessman, US President.
(1955 - ) American businessman, founder of Microsoft
(1942 - 2016) American Boxer and civil rights campaigner
(1869 - 1948) Leader of Indian independence movement
(1925 - 2013) British Prime Minister 1979 - 1990
(1910 - 1997) Macedonian Catholic missionary nun
(1451 - 1506) Italian explorer
(1809 - 1882) British scientist, theory of evolution
(1935 - 1977) American musician
(1879 - 1955) German scientist, theory of relativity
(1942 - ) British musician, member of Beatles
( 1819 - 1901) British monarch 1837 - 1901
(1936 - ) First pope from the Americas
(1889 - 1964) Indian Prime Minister 1947 - 1964
(1452 - 1519) Italian, painter, scientist, polymath
(1853 - 1890) Dutch artist
(1882 - 1945) US President 1932 - 1945
(1920 - 2005) Polish Pope
( 1847 - 1931) American inventor
(1913 - 2005) American civil rights activist
(1908 - 1973) US President 1963 - 1969
(1770 - 1827) German composer
(1954 - ) American TV presenter, actress, entrepreneur
(1917 - 1984) Prime Minister of India 1966 - 1977
(1919 - 1952) First Lady of Argentina 1946 - 1952
(1953 - 2007) Prime Minister of Pakistan 1993 - 1996
(1903 - 1950) British author
(1931 - ) South African Bishop and opponent of apartheid
(1938 - ) Spiritual and political leader of Tibetans
(1901 - 1966) American film producer
(1930 - 2012) US astronaut
(1925 - 1980) British actor and comedian
(1961 - ) US President 2008 - 2016
(1925 - 1965) American Black nationalist leader
(1965 - ) British author
(1950 - ) British entrepreneur
(1940 - ) Brazilian footballer, considered greatest of 20th
century.
(1975 - ) Actress, director, humanitarian
(1913 - 1980) US track athlete, 1936 Olympics
(1940 - 1980) British musician, member of the Beatles
(1863 - 1947) US Industrialist
(1892 - 1975) Emperor of Ethiopia 1930 - 1974
(1879 - 1953) Leader of Soviet Union 1924 - 1953
(1857 - 1941) British Founder of scout movement
(1963 - ) US Basketball star
(1946 - ) US President 2000-2008
(1870 - 1924) Leader of Russian Revolution 1917
(1915 - 1982) Swedish actress
(1926 - ) President of Cuba 1976 - 2008
(1828 - 1910) Russian author and philosopher
(2003 - ) Environmentalist activist)
(1881 - 1973) Spanish modern artist
(1854 - 1900) Irish author, poet, playwright
(1883 - 1971) French fashion designer
(1890 - 1970) French resistance leader and President 1959 -
1969
(1897 - 1937) Aviator
(1883 - 1946) British economist
(1822 - 1895) French chemist and microbiologist
(1931 - ) Leader of Soviet Union 1985 - 1991
(423 BC - 348 BC) Greek philosopher
(1889 - 1945) leader of Nazi Germany 1933 - 1945
(1951 - ) British musician
(4 BCE - 40CE) devotee of Jesus Christ
(1899 - 1980) English / American film producer, director
(1958 - 2009) American musician
(1958 - ) American musician, actress, author
(1876 - 1917) Dutch exotic dancer, executed as spy
(69 - 30 BCE) Queen of Egypt
(1929 - 1982) American actress, Princess of Monaco
(1955 - 2012) co-founder of Apple computers
(1911 - 2004) US President 1981-1989
(1987 - ) Argentinian footballer
(1895 - 1948) American baseball player
(1951 - ) Irish musician, charity worker
(1879 - 1940) Russian Marxist revolutionary
(1981 - ) Swiss Tennis player
(1856 - 1939) Austrian psychoanalyst
(1856 - 1924) US president 1913 - 1921
(1893 - 1976) Leader of Chinese Communist revolution
(1907 - 2003) American actress
(1929 - 1993) British actress and humanitarian
(1975 - ) English footballer
(1975 - ) American golfer
(1986 - ) Jamaican athlete and Olympian
(1961 - ) US athlete and Olympian
(1948 - ) Heir to British throne
(1929 - 1994) American wife of JF Kennedy
(1898 - 1963) British author
(1915 - 1959) American jazz singer
(1892 - 1973) British author
(1943 - ) American tennis player and human rights activist
(1929 - 1945) Dutch Jewish author who died
(1783 - 1830) Venezuelan independence activist in South America
C++ CODE:
INPUT FILES USED:
names.txt:
descriptions.txt:
OUTPUT:
FOR ANY HELP JUST DROP A COMMENT