From 0f47048363f660b0ef653fa0dda4611adcf71ff4 Mon Sep 17 00:00:00 2001 From: Shubhadip Bhowmik Date: Tue, 28 May 2024 23:09:14 +0530 Subject: [PATCH] ALL Content Task Uploaded With proper Structure --- blog/2024-05-23-hello-world/index.md | 2 +- docs/day-01/getting-started-with-cpp.md | 15 +++++ docs/day-01/history-of-cpp.md | 5 +- docs/day-01/introduction-to-cpp.md | 3 +- docs/day-02/comments-in-cpp.md | 17 ++++++ docs/day-02/first-cpp-program.md | 14 +++++ docs/day-02/keywords-identifiers.md | 17 ++++++ docs/day-02/variables-in-cpp.md | 55 ------------------- docs/day-03/_category_.json | 7 +++ docs/day-03/cpp-type-modifiers.md | 20 +++++++ docs/day-03/datatypes-in-cpp.md | 15 +++++ .../variables-literals-constant-in-cpp.md | 32 +++++++++++ docs/day-04/_category_.json | 7 +++ docs/day-04/constants-in-cpp.md | 17 ++++++ docs/day-04/input-output-in-cpp.md | 15 +++++ docs/day-04/operators-in-cpp.md | 13 +++++ docs/day-05/_category_.json | 7 +++ docs/day-05/do-while-loop.md | 17 ++++++ docs/day-05/for-loop.md | 15 +++++ docs/day-05/if-else-statement.md | 18 ++++++ docs/intro.mdx | 8 ++- 21 files changed, 257 insertions(+), 62 deletions(-) create mode 100644 docs/day-01/getting-started-with-cpp.md create mode 100644 docs/day-02/comments-in-cpp.md create mode 100644 docs/day-02/first-cpp-program.md create mode 100644 docs/day-02/keywords-identifiers.md delete mode 100644 docs/day-02/variables-in-cpp.md create mode 100644 docs/day-03/_category_.json create mode 100644 docs/day-03/cpp-type-modifiers.md create mode 100644 docs/day-03/datatypes-in-cpp.md create mode 100644 docs/day-03/variables-literals-constant-in-cpp.md create mode 100644 docs/day-04/_category_.json create mode 100644 docs/day-04/constants-in-cpp.md create mode 100644 docs/day-04/input-output-in-cpp.md create mode 100644 docs/day-04/operators-in-cpp.md create mode 100644 docs/day-05/_category_.json create mode 100644 docs/day-05/do-while-loop.md create mode 100644 docs/day-05/for-loop.md create mode 100644 docs/day-05/if-else-statement.md diff --git a/blog/2024-05-23-hello-world/index.md b/blog/2024-05-23-hello-world/index.md index 760d982a2..0c0383fd1 100644 --- a/blog/2024-05-23-hello-world/index.md +++ b/blog/2024-05-23-hello-world/index.md @@ -2,7 +2,7 @@ slug: hello-world title: Hello World authors: [shubhadip] -tags: ["30daysocpp", "first-blog", "opensource"] +tags: ["30daysofcpp", "first-blog", "opensource"] --- ## Hello World diff --git a/docs/day-01/getting-started-with-cpp.md b/docs/day-01/getting-started-with-cpp.md new file mode 100644 index 000000000..06f52dfed --- /dev/null +++ b/docs/day-01/getting-started-with-cpp.md @@ -0,0 +1,15 @@ +--- +sidebar_position: 3 +title: "Getting Started with CPP" +description: "Welcome to the world of CPP programming Learn about the key features of CPP, its applications, and how to get started with C Plus Plus programming" +sidebar_label: "Getting Started with C++" +slug: getting-started-with-cpp +--- + +import CustomTag from '@site/src/components/TagsComponents/CustomTag'; + +TASK: + +1. Installation Process Step By Step +2. How to run a CPP program +3. How to compile a CPP program diff --git a/docs/day-01/history-of-cpp.md b/docs/day-01/history-of-cpp.md index c868d83c5..930b433fd 100644 --- a/docs/day-01/history-of-cpp.md +++ b/docs/day-01/history-of-cpp.md @@ -1,11 +1,12 @@ --- -sidebar_position: 3 +sidebar_position: 2 title: "History of C++" description: "Learn about the history of C++, its key features, and how it has evolved over time." sidebar_label: "History of C++" +slug: /history-of-cpp --- -# History of CPP +## History of CPP Welcome to the world of C++ programming! C++ is a powerful and versatile programming language widely used for developing various applications, ranging from system software, games, and embedded systems to high-performance applications. diff --git a/docs/day-01/introduction-to-cpp.md b/docs/day-01/introduction-to-cpp.md index 9224f410c..29936e924 100644 --- a/docs/day-01/introduction-to-cpp.md +++ b/docs/day-01/introduction-to-cpp.md @@ -3,11 +3,12 @@ sidebar_position: 1 title: "Introduction to CP" description: "Welcome to the world of CPP programming! Learn about the key features of C++, its applications, and how to get started with C programming" sidebar_label: "Introduction to C++" +slug: introduction-to-cpp --- import CustomTag from '@site/src/components/TagsComponents/CustomTag'; -# Introduction to C++ +## Introduction to C++ Welcome to the world of C++ programming programming! C++ is a powerful and versatile programming language widely used for developing various applications, ranging from system software, games, and embedded systems to high-performance applications. diff --git a/docs/day-02/comments-in-cpp.md b/docs/day-02/comments-in-cpp.md new file mode 100644 index 000000000..c0cf2ae44 --- /dev/null +++ b/docs/day-02/comments-in-cpp.md @@ -0,0 +1,17 @@ +--- +sidebar_position: 2 +title: "Comment in C++" +description: "This is a simple program to demonstrate the use of comments in C Plus Plus." +sidebar_label: "Comment" +slug: comment-in-cpp +--- + +TASK: + +1. What is Comment in C++? +2. Why do we use comments in C++? +3. Write a simple program to demonstrate the use of comments in C++. +4. Types of comments in C++ + i. Single Line Comment + ii. Multi Line Comment + iii. Documentation Comment \ No newline at end of file diff --git a/docs/day-02/first-cpp-program.md b/docs/day-02/first-cpp-program.md new file mode 100644 index 000000000..a89ddbc1d --- /dev/null +++ b/docs/day-02/first-cpp-program.md @@ -0,0 +1,14 @@ +--- +sidebar_position: 1 +title: "First CPP Program" +description: "Learn how to write and execute your first C Plus Plys program using a simple 'Hello, World!' example." +sidebar_label: "First CPP Program" +slug: first-cpp-program +--- + +TASK: + +1. Write a simple "Hello, World!" program in C++. +2. Output of the program. +3. Explain the code line by line. +4. Explain Basic Structure of C++ Program. diff --git a/docs/day-02/keywords-identifiers.md b/docs/day-02/keywords-identifiers.md new file mode 100644 index 000000000..4c48c51a2 --- /dev/null +++ b/docs/day-02/keywords-identifiers.md @@ -0,0 +1,17 @@ +--- +sidebar_position: 3 +title: "Keywords and Identifiers in C++" +description: "Keywords and Identifiers in C++. This is a simple program to demonstrate the use of keywords and identifiers in C Plus Plus." +sidebar_label: "Keywords and Identifiers" +slug: keywords-and-identifiers-in-cpp +--- + +TASK: + +1. What is Keywords and Identifiers in C++? +2. Why do we use Keywords and Identifiers in C++? +3. Write a simple program to demonstrate the use of Keywords and Identifiers in C++. +4. List of Keywords in C++ +5. Rules for defining Identifiers in C++ +6. Examples of Identifiers in C++ +7. Difference between Keywords and Identifiers in C++ \ No newline at end of file diff --git a/docs/day-02/variables-in-cpp.md b/docs/day-02/variables-in-cpp.md deleted file mode 100644 index 7401b6279..000000000 --- a/docs/day-02/variables-in-cpp.md +++ /dev/null @@ -1,55 +0,0 @@ -# Variables in CPP - -Welcome to the world of C++ programming! C++ is a powerful and versatile programming language widely used for developing various applications, ranging from system software, games, and embedded systems to high-performance applications. - -## What is C++? - -C++ is an extension of the C programming language with added features such as object-oriented programming (OOP) capabilities. It provides a robust set of tools and allows low-level memory manipulation while also supporting high-level abstractions. Known for its efficiency and performance, C++ is often chosen for applications that require speed and resource management. - -## Key Features of C++ - -### Object-Oriented Programming (OOP) - -C++ supports the principles of OOP, enabling developers to create classes, objects, inheritance, polymorphism, encapsulation, and abstraction. This paradigm helps in organizing and structuring code for better maintainability and reusability. - -### Standard Template Library (STL) - -The Standard Template Library in C++ provides a collection of classes and functions that implement various common data structures (like arrays, vectors, lists, maps) and algorithms (such as sorting, searching). This library simplifies complex tasks and enhances productivity. - -### Performance and Efficiency - -C++ allows fine-tuning of performance-critical parts of code by providing control over memory management and offering features like inline functions, which can significantly enhance execution speed. - -### Portability - -C++ code can be compiled on different platforms with minimal changes, making it a portable language suitable for cross-platform development. - -## Getting Started - -To start programming in C++, you'll need a development environment with a C++ compiler. Popular compilers include GCC, Clang, and Microsoft Visual C++. You can choose an Integrated Development Environment (IDE) like Visual Studio, Code::Blocks, or CLion to write and compile your code efficiently. - -Here's a simple "Hello, World!" example in C++: - -```cpp -#include - -int main() { - std::cout << "Hello, World!" << std::endl; - return 0; -} -``` - -Save this code in a file with a `.cpp` extension, compile it using a C++ compiler, and execute the resulting program to see the output. - -## What's Next? - -- **Learn Basic Syntax**: Dive into the syntax, data types, control structures, and functions in C++. -- **Explore Advanced Concepts**: Study topics like pointers, memory management, templates, and exception handling. -- **Practice, Practice, Practice**: Solve programming challenges and work on projects to reinforce your learning. -- **Refer Official Documentation**: Utilize online resources, books, and official C++ references to deepen your understanding. - -C++ is a vast language with numerous possibilities. Enjoy your journey in mastering this versatile programming language! - ---- - -Feel free to expand upon this content and include more details, examples, or exercises based on your audience's needs and the depth of the tutorial you're planning to create. diff --git a/docs/day-03/_category_.json b/docs/day-03/_category_.json new file mode 100644 index 000000000..91740c50d --- /dev/null +++ b/docs/day-03/_category_.json @@ -0,0 +1,7 @@ +{ + "label": "Day 03", + "position": 4, + "link": { + "type": "generated-index" + } +} diff --git a/docs/day-03/cpp-type-modifiers.md b/docs/day-03/cpp-type-modifiers.md new file mode 100644 index 000000000..4544ff3e2 --- /dev/null +++ b/docs/day-03/cpp-type-modifiers.md @@ -0,0 +1,20 @@ +--- +sidebar_position: 3 +title: "Type Modifiers in C++" +description: "Type modifiers are used to change the meaning of the fundamental data types. In this tutorial, we will learn about type-modifiers and how to use them in C++ programming with the help of examples." +sidebar_label: "Type Modifiers" +slug: type-modifiers-in-cpp +--- + +TASK: + +1. What is Type Modifiers in C++? +2. Types of Type Modifiers in C++ with Proper Examples. +3. short type Modifier +4. long type Modifier +5. signed type Modifier +6. unsigned type Modifier +7. long long type Modifier +8. short int type Modifier +9. long int type Modifier +10. long double type Modifier \ No newline at end of file diff --git a/docs/day-03/datatypes-in-cpp.md b/docs/day-03/datatypes-in-cpp.md new file mode 100644 index 000000000..34b3f1bfb --- /dev/null +++ b/docs/day-03/datatypes-in-cpp.md @@ -0,0 +1,15 @@ +--- +sidebar_position: 2 +title: "Data Types in C++" +description: "In this tutorial, we will learn about basic data types such as int, float, char, etc. in C++ programming with the help of examples. A data type determines the type and size of an variable." +sidebar_label: "Datatypes" +slug: data-types-in-cpp +--- + +TASK: + +1. What is Data Types in C++? +2. C++ Fundamental Data Types +3. Examples of Data Types in C++ +4. C++ Modified Data Types List +5. Derived Data Types in C++ \ No newline at end of file diff --git a/docs/day-03/variables-literals-constant-in-cpp.md b/docs/day-03/variables-literals-constant-in-cpp.md new file mode 100644 index 000000000..b9a7b6377 --- /dev/null +++ b/docs/day-03/variables-literals-constant-in-cpp.md @@ -0,0 +1,32 @@ +--- +sidebar_position: 1 +title: "Variables, Literals, and Constants in C++" +description: "This is a simple program to demonstrate the use of variables, literals, and constants in C Plus Plus." +sidebar_label: "Variables, Literals, and Constants" +slug: variables-literals-constant-in-cpp +--- + +TASK: + +1. What is Variables, Literals, and Constants in C++? +2. Why do we use Variables, Literals, and Constants in C++? +3. Write a simple program to demonstrate the use of Variables, Literals, and Constants in C++. +4. Types of Variables in C++ + i. Local Variables + ii. Global Variables + iii. Static Variables + iv. Register Variables +5. Types of Literals in C++ + i. Integer Literals + ii. Floating Point Literals + iii. Character Literals + iv. String Literals + v. Boolean Literals + vi. Pointer Literals +6. Types of Constants in C++ + i. Integer Constants + ii. Floating Point Constants + iii. Character Constants + iv. String Constants + v. Boolean Constants + vi. Pointer Constants diff --git a/docs/day-04/_category_.json b/docs/day-04/_category_.json new file mode 100644 index 000000000..69bcfe455 --- /dev/null +++ b/docs/day-04/_category_.json @@ -0,0 +1,7 @@ +{ + "label": "Day 04", + "position": 5, + "link": { + "type": "generated-index" + } +} diff --git a/docs/day-04/constants-in-cpp.md b/docs/day-04/constants-in-cpp.md new file mode 100644 index 000000000..2066a8eb7 --- /dev/null +++ b/docs/day-04/constants-in-cpp.md @@ -0,0 +1,17 @@ +--- +sidebar_position: 1 +title: "Constants in C++" +description: "The C++ const keyword is used to specify that the value of a variable cannot be changed. In this tutorial, you will learn about C++ constants with the help of examples." +sidebar_label: "Constants" +slug: constants-in-cpp +--- + +TASK: + +1. What is Constants in C++? +2. How to Declare Constants in C++? +3. How to Define Constants in C++? +4. How to Use Constants in C++? +5. What are the Advantages of Constants in C++? +6. Best Practices for Using Constants in C++. +7. Examples of Constants in C++. \ No newline at end of file diff --git a/docs/day-04/input-output-in-cpp.md b/docs/day-04/input-output-in-cpp.md new file mode 100644 index 000000000..924de1fb2 --- /dev/null +++ b/docs/day-04/input-output-in-cpp.md @@ -0,0 +1,15 @@ +--- +sidebar_position: 2 +title: "Input and Output in C++" +description: "In this tutorial, we will learn to use the cin object to take input from the user, and the cout object to display output to the user with the help of examples." +sidebar_label: "Input and Output" +slug: input-output-in-cpp +--- + +TASK: + +1. What is Input and Output in C++? +2. Why do we use Input and Output in C++? +3. How to take input from the user in C++? +4. How to display output to the user in C++? +5. Take Multiple Inputs from the User in C++. diff --git a/docs/day-04/operators-in-cpp.md b/docs/day-04/operators-in-cpp.md new file mode 100644 index 000000000..cf84bc11c --- /dev/null +++ b/docs/day-04/operators-in-cpp.md @@ -0,0 +1,13 @@ +--- +sidebar_position: 3 +title: "Operators in C++" +description: "In this tutorial, we will learn about the different types of operators in C++ with the help of examples. In programming, an operator is a symbol that operates on a value or a variable." +sidebar_label: "Operators" +slug: operators-in-cpp +--- + +TASK: + +1. What is Operators in C++? +2. Types of Operators in C++. +3. Explain All the Operators in C++ with Proper Examples. diff --git a/docs/day-05/_category_.json b/docs/day-05/_category_.json new file mode 100644 index 000000000..47132fb0c --- /dev/null +++ b/docs/day-05/_category_.json @@ -0,0 +1,7 @@ +{ + "label": "Day 05", + "position": 6, + "link": { + "type": "generated-index" + } +} diff --git a/docs/day-05/do-while-loop.md b/docs/day-05/do-while-loop.md new file mode 100644 index 000000000..df8b69866 --- /dev/null +++ b/docs/day-05/do-while-loop.md @@ -0,0 +1,17 @@ +--- +sidebar_position: 3 +title: "While and Do-While Loop in C++" +description: "In this tutorial, we will learn about the while and do-while loop in C++ programming with the help of examples. The while loop is used to execute a block of code multiple times." +sidebar_label: "While and Do-While Loop" +slug: while-and-do-while-loop-in-cpp +--- + +TASK: + +1. C++ while and do...while Loop +2. C++ while Loop +3. Flowchart of while Loop +4. Example 1: Display Numbers from 1 to 5 +5. C++ do...while Loop +6. Flowchart of do...while Loop +7. Example 2: Display Numbers from 1 to 5 diff --git a/docs/day-05/for-loop.md b/docs/day-05/for-loop.md new file mode 100644 index 000000000..5522bee99 --- /dev/null +++ b/docs/day-05/for-loop.md @@ -0,0 +1,15 @@ +--- +sidebar_position: 2 +title: "For Loop in C++" +description: "In this tutorial, we will learn about the for loop in C++ programming with the help of examples. The for loop is used to execute a block of code multiple times." +sidebar_label: "For Loop" +slug: for-loop-in-cpp +--- + +TASK: + +1. What is the For Loop in C++? +2. Explain the Syntax of For Loop in C++. +3. C++ for Loop Example +4. C++ Infinite for Loop +5. C++ Nested for Loop diff --git a/docs/day-05/if-else-statement.md b/docs/day-05/if-else-statement.md new file mode 100644 index 000000000..81071d44f --- /dev/null +++ b/docs/day-05/if-else-statement.md @@ -0,0 +1,18 @@ +--- +sidebar_position: 1 +title: "IF-ELSE Statement in C++" +description: "The if...else statement is used to run one block of code under certain conditions and another block of code under different conditions. In this tutorial, we will learn C++ if, if…else and nested if…else with the help of examples.." +sidebar_label: "IF-ELSE Statement" +slug: if-else-statement-in-cpp +--- + +TASK: + +1. What is Control Statements in C++? +2. What is the IF-ELSE Statement in C++? +3. Explain the Syntax of IF-ELSE Statement in C++. +4. C++ if Statement +5. C++ if-else Statement +6. C++ Nested if-else Statement +7. C++ if-else-if Ladder +8. C++ Ternary Operator \ No newline at end of file diff --git a/docs/intro.mdx b/docs/intro.mdx index 5f184855f..38f0df67f 100644 --- a/docs/intro.mdx +++ b/docs/intro.mdx @@ -1,11 +1,13 @@ --- sidebar_position: 1 description: "Introduction to C. Introduction to 30 Days of CPP. This tutorial will give you a good introduction to the programming language. This tutorial series is best for beginners to start with C programming." -sidebar_label: "Whst is 30 Days of CPP?" -title: "What is 30 Days of CPP?" +sidebar_label: "What is 30 Days of CPP?" +title: "What is 30 Days of CPP" +keywords: ["30daysofcpp", "cpp-introduction", "learn-cpp"] +slug: /intro --- -# Introduction to 30 Days of CPP +## Introduction to 30 Days of CPP Congratulations on deciding to participate in 30 days of CPP programming challenge. In this challenge you will learn everything you need to be a CPP programmer, and in general, the whole concept of programming. In case you need help or if you would like to help others you may join the [Whatsapp Channel](https://whatsapp.com/channel/0029Vaf19w1CsU9VVaQr8e20).