AmericanRevolutionManager.ipynb

In [1]:
from xv.history.managers import AmericanRevolutionManager
In [2]:
ke = AmericanRevolutionManager(verbose = False)
In [3]:
ke.printProblemTypes()
0. _problem_introduction
1. _problem_random_question_from_rich_text
2. _problem_american_president_timeline
3. _problem_american_president_not_in_list
4. _problem_american_president_in_list
5. _problem_american_presidents_match
6. _problem_random_saq_question
7. _problem_random_mcq_question
In [4]:
ke.getRandomProblem(problem_type = 7)
Out[4]:
Benjamin Franklin's famous "Join or Die" political cartoon was drawn
  1. In 1765 to support the Stamp Act Congress
  2. In 1775 to support the Second Continental Congress
  3. In 1774 to support the First Continental Congress
  4. In 1754 to support the Albany Congress
In [5]:
ke.printAnswer()
Out[5]:
4. In 1754 to support the Albany Congress
In [6]:
ke.printSolution()
Out[6]:
Question. Benjamin Franklin's famous "Join or Die" political cartoon was drawn
  1. In 1765 to support the Stamp Act Congress
  2. In 1775 to support the Second Continental Congress
  3. In 1774 to support the First Continental Congress
  4. In 1754 to support the Albany Congress


Answer. 4. In 1754 to support the Albany Congress
In [ ]:
 
In [7]:
from IPython.display import HTML
n = len(ke._problemTemplates)
max_loop = 1
for j in range(0, max_loop):
    for i in range(n):
        problem_type = i
        display(HTML(f"<h2>problem_type: {problem_type}/{n-1} (loop {j}/{max_loop-1})</h2>"))
        ke.getRandomProblem(problem_type = problem_type, verbose = True)
        display(ke.printProblem())

        display(HTML(f"<h6>Answer:</h6>"))
        display(ke.printAnswer())

        display(HTML(f"<h6>Solution:</h6>"))
        display(ke.printSolution())
        pass

problem_type: 0/7 (loop 0/0)

Problem Template: _problem_introduction
Introduction to American Revolution
Answer:
Solution:

problem_type: 1/7 (loop 0/0)

Problem Template: _problem_random_question_from_rich_text
Unscramble the word:
binlel hurk

The word has been taken from the following paragraph:
The Second Continental Congress chose George Washington, a southerner, to command the militiamen besieging Boston in the north. They also appropriated money for a small navy and for transforming the undisciplined militias into the professional Continental Army. Encouraged by a strong colonial campaign in which the British scored only narrow victories (such as at Bunker Hill), many colonists began to advocate total independence as opposed to having full rights within the British Empire. The next year, the congressmen voted on July 2, 1776, to declare their independence. Thomas Jefferson, a young lawyer from Virginia, drafted the Declaration Of Independence. The United States was born.
Answer:
bunker hill
Solution:
bunker hill

The Second Continental Congress chose George Washington, a southerner, to command the militiamen besieging Boston in the north. They also appropriated money for a small navy and for transforming the undisciplined militias into the professional Continental Army. Encouraged by a strong colonial campaign in which the British scored only narrow victories (such as at Bunker Hill), many colonists began to advocate total independence as opposed to having full rights within the British Empire. The next year, the congressmen voted on July 2, 1776, to declare their independence. Thomas Jefferson, a young lawyer from Virginia, drafted the Declaration Of Independence. The United States was born.

problem_type: 2/7 (loop 0/0)

Problem Template: _problem_american_president_timeline
Arrange the presidents of USA in timeline order:
  1. George Washington
  2. Thomas Jefferson
  3. John Adams
  4. James Madison
Answer:
  1. George Washington
  2. John Adams
  3. Thomas Jefferson
  4. James Madison
Solution:
  1. George Washington
  2. John Adams
  3. Thomas Jefferson
  4. James Madison

problem_type: 3/7 (loop 0/0)

Problem Template: _problem_american_president_not_in_list
Who is not among the last four presidents of USA?
  1. Joe Biden
  2. George Washington
  3. Barack Obama
  4. George W. Bush
Answer:
George Washington
Solution:
George Washington

The last four presidents of USA:
  1. George W. Bush
  2. Barack Obama
  3. Donald Trump
  4. Joe Biden

problem_type: 4/7 (loop 0/0)

Problem Template: _problem_american_president_in_list
Who is among the last four presidents of USA?
  1. William Howard Taft
  2. Gerald Ford
  3. Joe Biden
  4. James Madison
Answer:
Joe Biden
Solution:
Joe Biden

The last four presidents of USA:
  1. George W. Bush
  2. Barack Obama
  3. Donald Trump
  4. Joe Biden

problem_type: 5/7 (loop 0/0)

Problem Template: _problem_american_presidents_match
Match the USA presidents with the year they became president?
John Adams1789
Theodore Roosevelt1797
George Washington1901
Gerald Ford1974
Answer:
John Adams1797
Theodore Roosevelt1901
George Washington1789
Gerald Ford1974
Solution:
John Adams1797
Theodore Roosevelt1901
George Washington1789
Gerald Ford1974


List of USA presidents with the year they became president?
George Washington1789
John Adams1797
Thomas Jefferson1801
James Madison1809
James Monroe1817
John Quincy Adams1825
Andrew Jackson1829
Martin Van Buren1837
William Henry Harrison1841
John Tyler1841
James K. Polk1845
Zachary Taylor1849
Millard Fillmore1850
Franklin Pierce1853
James Buchanan1857
Abraham Lincoln1861
Andrew Johnson1865
Ulysses S. Grant1869
Rutherford B. Hayes1877
James A. Garfield1881
Chester A. Arthur1881
Grover Cleveland1885
Benjamin Harrison1889
Grover Cleveland1893
William McKinley1897
Theodore Roosevelt1901
William Howard Taft1909
Woodrow Wilson1913
Warren G. Harding1921
Calvin Coolidge1923
Herbert Hoover1929
Franklin D. Roosevelt1933
Harry S. Truman1945
Dwight D. Eisenhower1953
John F. Kennedy1961
Lyndon B. Johnson1963
Richard Nixon1969
Gerald Ford1974
Jimmy Carter1977
Ronald Reagan1981
George H. W. Bush1989
Bill Clinton1993
George W. Bush2001
Barack Obama2009
Donald Trump2017
Joe Biden2021

problem_type: 6/7 (loop 0/0)

Problem Template: _problem_random_saq_question
Which Continental congress produced the Olive Branch Petition ?
Answer:
Second Continental Congress
Solution:
Question. Which Continental congress produced the Olive Branch Petition ?

Answer. Second Continental Congress

problem_type: 7/7 (loop 0/0)

Problem Template: _problem_random_mcq_question
With which country did the United States forge a military alliance in 1778?
  1. Austria
  2. France
  3. Spain
  4. Russia
Answer:
2. France
Solution:
Question. With which country did the United States forge a military alliance in 1778?
  1. Austria
  2. France
  3. Spain
  4. Russia


Answer. 2. France
In [ ]:
 

Machine Learning

  1. Deal Banking Marketing Campaign Dataset With Machine Learning

TensorFlow

  1. Difference Between Scalar, Vector, Matrix and Tensor
  2. TensorFlow Deep Learning Model With IRIS Dataset
  3. Sequence to Sequence Learning With Neural Networks To Perform Number Addition
  4. Image Classification Model MobileNet V2 from TensorFlow Hub
  5. Step by Step Intent Recognition With BERT
  6. Sentiment Analysis for Hotel Reviews With NLTK and Keras
  7. Simple Sequence Prediction With LSTM
  8. Image Classification With ResNet50 Model
  9. Predict Amazon Inc Stock Price with Machine Learning
  10. Predict Diabetes With Machine Learning Algorithms
  11. TensorFlow Build Custom Convolutional Neural Network With MNIST Dataset
  12. Deal Banking Marketing Campaign Dataset With Machine Learning

PySpark

  1. How to Parallelize and Distribute Collection in PySpark
  2. Role of StringIndexer and Pipelines in PySpark ML Feature - Part 1
  3. Role of OneHotEncoder and Pipelines in PySpark ML Feature - Part 2
  4. Feature Transformer VectorAssembler in PySpark ML Feature - Part 3
  5. Logistic Regression in PySpark (ML Feature) with Breast Cancer Data Set

PyTorch

  1. Build the Neural Network with PyTorch
  2. Image Classification with PyTorch
  3. Twitter Sentiment Classification In PyTorch
  4. Training an Image Classifier in Pytorch

Natural Language Processing

  1. Spelling Correction Of The Text Data In Natural Language Processing
  2. Handling Text For Machine Learning
  3. Extracting Text From PDF File in Python Using PyPDF2
  4. How to Collect Data Using Twitter API V2 For Natural Language Processing
  5. Converting Text to Features in Natural Language Processing
  6. Extract A Noun Phrase For A Sentence In Natural Language Processing