Write a piece of code that prompts the user for a number and then prints a different

Question:

Write a piece of code that prompts the user for a number and then prints a different message depending on whether the number was an integer or a real number. Here are two sample dialogues:

Type a number: 42.5
You typed the real number 42.5

Type a number: 3
You typed the integer 3

Fantastic news! We've Found the answer you've been seeking!

Step by Step Answer:

Related Book For  book-img-for-question
Question Posted: