Main File & Main Function Explained

This metaphor will help you understand programming concepts more easily and remember them better. What you’ll learn in this video: How to compare a project folder with house land Why main.c works like the main gate of a program How the main function is like the first room you enter Key features of C files (.c extension) Importance of #include [stdio.h], int main(), and return 0;

File append

Extend text file কিভাবে File Append ব্যবহার করে ফাইলের শেষে নতুন text add করা যায়। ভিডিওতে step by step code example, practical demonstration এবং beginner-friendly explanation দেখানো হয়েছে। Code #include <stdio.h> int main() { FILE *newFile = fopen("my_file.txt", "a+"); // append + read if (newFile == NULL) { printf("failed to open the file.\n"); return 1; } // Write 10 lines for (int i = 0; i < 10; i++) fputs("something\n", newFile); // Rewind to start of file before reading rewind(newFile); char str[100]; while (fgets(str, sizeof(str), newFile) != NULL) { puts(str); } fclose(newFile); return 0; }

File SEEK

Get & Update Cursor Position File Seek ব্যবহার করে cursor position পাওয়া এবং update করা যায়। ভিডিওতে দেখানো হয়েছে ftell এবং fseek ব্যবহার, cursor move, text replace, এবং practical examples step by step। Beginners এবং self-learners এর জন্য সহজ ব্যাখ্যা। fseek() কী? fseek() দিয়ে ফাইল পয়েন্টারকে ফাইলের যেকোনো স্থানে সরানো যায়। Syntax: int fseek(FILE *stream, long int offset, int whence); offset হলো কত দূরে সরাতে হবে। whence হলো কোন পয়েন্ট থেকে শুরু হবে: ...

Number Guessing Game in C

How random works? #include <stdlib.h> int r = rand(); Generates a pseudo-random number between 0 and RAND_MAX. Without seeding, the sequence is the same every run. 🌱 Seeding with srand() #include <time.h> srand(time(0)); srand() sets the starting point (seed) for rand(). time(0) and time(NULL) both give current time in seconds since 1970. Using time as a seed ensures different sequences each run. “By using the current time as a seed, we make the numbers look random every time the program runs.” Random Numbers in a Range To generate a number between min and max: ...

Pyramid Patterns in C

Pyramid Top to Bottom Print pyramid patterns from top to bottom. #include <stdio.h> int main() { int n; printf("Enter Number of rows:"); scanf("%d", &n); for (int i = 0; i < n; i++) { for (int s = 0; s < n - i - 1; s++) printf(" "); for (int j = 0; j < 2 * i + 1; j++) { printf("*"); } printf("\n"); } return 0; } Upside Pyramid Print upside-down pyramid patterns step by step. #include <stdio.h> int main() { int n; printf("Enter Number of rows:"); scanf("%d", &n); for (int i = 0; i < n; i++) { for (int s = 0; s < i; s++) printf(" "); for (int j = 0; j < 2 * (n - i) - 1; j++) { printf("*"); } printf("\n"); } return 0; } Hollow Upside Pyramid #include <stdio.h> int main() { int n ; printf("Enter Number of rows:"); scanf("%d", &n); for (int i=0; i< n; i++){ for(int s=0; s<i;s++) printf(" "); for(int j=0; j<2*(n-i)-1; j++){ if(j==0||i==0 ||j==2*(n-i)-2 ) printf("*"); else printf(" "); } printf("\n"); } return 0; } Pyramid with Space Top to bottom #include <stdio.h> int main() { int n ; printf("Enter Number of rows:"); scanf("%d", &n); for (int i=0; i< n; i++){ for(int s=0; s<n-i-1;s++) printf(" "); for(int j=0; j<2*i+1; j++){ if(j==0||i==n-1 ||j==2*i) printf("*"); else printf(" "); } printf("\n"); } return 0; }

Dynamic Memory uses

Create Lets create an integer array of 3 elements. Dynamic Memory behaves like an array, and its dataType specified by the type of pointer. int size = 3 * sizeof(*int); int *ptr = malloc(size); Now we can use 0,1,2 indexes to access the Memory; ptr[0] =5; // we can also use `*ptr` while default it point to 1st index(0) ptr[2] = 4; printf("%d \n", ptr[2]); We can also use calloc(3, sizeof(*ptr)) ...

Prefix Postfix

Prefix & Postfix Operators in C | ++ & – Explained Iso_C_1999_definition

Array 2D & 3D

2D array basics, index calculation, value assignment, এবং 3D array coding step by step। 2D array 3D array

Function Practice

ভিডিওতে আপনি শিখবেন: Function define করা Function ব্যবহার করা (Use) Return value বোঝা Pass value / Argument passing Sum calculation উদাহরণ

Loop, Break & Continue Explained

এই ভিডিওতে আমরা শিখব C Programming-এ লুপ (for, while, do-while) এর কাজ, এবং কীভাবে break ও continue স্টেটমেন্ট কাজ করে পুরো বিষয়টি animation দিয়ে ভিজ্যুয়ালি বোঝানো হয়েছে, যাতে সহজে মনে থাকে। What you’ll learn in this video: Basics of loops in C (for, while, do-while) Detailed explanation of break & continue Step-by-step Bangla explanation with animation Easy visualization for beginners and students