- Trending Categories
- Data Structure
- Networking
- RDBMS
- Operating System
- Java
- iOS
- HTML
- CSS
- Android
- Python
- C Programming
- C++
- C#
- MongoDB
- MySQL
- Javascript
- PHP

- Selected Reading
- UPSC IAS Exams Notes
- Developer's Best Practices
- Questions and Answers
- Effective Resume Writing
- HR Interview Questions
- Computer Glossary
- Who is Who

# Write down separately the prime and composite numbers less than 20 .

To do:

We have to write separately the prime and composite numbers less than 20.

Solution:

**Prime numbers** are those numbers that are divisible by themselves and 1.

**Composite numbers** are those numbers that are NOT prime numbers.

$2, 3, 5, 7, 11, 13, 17$ and $19$ are the prime numbers less than 20.

$4, 6, 8, 9, 10, 12, 14, 15, 16$ and $18$ are the composite numbers less than 20.

- Related Questions & Answers
- How to display random numbers less than 20 in Java
- Print all prime numbers less than or equal to N in C++
- Nearest prime less than given number n C++
- Print all Semi-Prime Numbers less than or equal to N in C++
- Count all the numbers less than 10^6 whose minimum prime factor is N C++
- Java Program to display a prime number less than the given number
- Count pairs with sum as a prime number and less than n in C++
- Print all Prime Quadruplet of a number less than it in C++
- Queries for greater than and not less than using C++
- Minimum number of sets with numbers less than Y in C++
- Absolute Difference between the Product of Non-Prime numbers and Prime numbers of an Array?
- Absolute Difference between the Sum of Non-Prime numbers and Prime numbers of an Array?
- Find all factorial numbers less than or equal to n in C++
- An interesting solution to get all prime numbers smaller than n?
- Prime numbers and Fibonacci in C++
- Difference between MySQL BigInt(20) and Int(20)?

Advertisements