This repository has a collection of questions related to technical topics in programming that can be used for competitions and testing concepts via quizzes. The questions can be Multiple Choice Questions, Short Answer or Coding based. An example for each type is given below so contributors can add any sort of question based on the format given.
All questions must be added to the file associated with the topics.
The format of the questions must be as given below:
[
{
"topic": "Python",
"subtopic": "Syntax",
"type": "MCQ",
"question": "How do you make a single line comment in Python?",
"options": ["#", "//", "!", "/"],
"answer": 0, // index of the correct option (0-based)
"difficulty": "Easy"
},
{
"topic": "Python",
"subtopic": "Strings",
"type": "Coding",
"question": "Write a program to reverse a given string.",
"options": null,
"answer": null,
"difficulty": "Easy"
},
{
"topic": "Python",
"subtopic": "Basics",
"type": "SA",
"question": "What is break, continue and pass in Python?",
"options": null,
"answer": "The break statement terminates the loop immediately and the control flows to the statement after the body of the loop. The continue statement terminates the current iteration of the statement, skips the rest of the code in the current iteration and the control flows to the next iteration of the loop. The pass keyword in Python is generally used to fill up empty blocks and is similar to an empty statement represented by a semi-colon in languages such as Java, C++, Javascript, etc.",
"difficulty": "Easy"
]
Raise a PR and if it follows the correct syntax and the data entered is corrected, the questions will be merged! ๐ ๐ ๐