Friday, February 26, 2021

Full Stack Implementation in C programming language

#include<stdio.h>
#include <stdbool.h>
#define max_size 100
int arr[max_size], top = -1;
bool isFull()
{
    if(top == (max_size - 1)){
        printf("Stack is Full!!\n");
        return true;
    }else{
        printf("Stack is Not Full!!!. You can insert Value!!\n");
        return false;
    }
}
bool isempty(){
    if(top == -1){
        return true;
    }else{
        return false;
    }
}
void push()
{
    if(isFull()){
        printf("Stack is Full!!\n");
    }else{
        int value;
        printf("Enter the value: ");
        scanf("%d", &value);
        top++;
        arr[top] = value;
        printf("%d is inserted into stack.\n", value);
    }
}
void pop()
{
    if(isempty()){
        printf("\nStack is Empty!!\n");
    }
    else{
        int value = arr[top];
        printf("%d is popped.\n", value);
        top = top - 1;
    }
}
void stack_size()
{
    printf("Size of the array is: %d.\n", top + 1);
}
void print_arr()
{
    printf("Array Elements are: ");
    for(int i = 0; i < (top + 1); i++){
        printf("%d ", arr[i]);
    }
    printf("\n\n");
}
int main()
{
    int n;
    while(1){
        printf("Press 1 for push 2 for pop 3 for array elements 4 for size: ");
        scanf("%d", &n);
        switch(n){
        case 1:
            push();
            break;
        case 2:
            pop();
            break;
        case 3:
            print_arr();
            break;
        case 4:
            stack_size();
            break;
        }
    }
    return 0;
}

Monday, February 22, 2021

E-commerce system project using PHP(Laravel), Javascript, JQuery, Bootst...

E-commerce system project using PHP(Laravel), Javascript, JQuery, Bootstrap, MySQL with source code. Ecommerce, also known as electronic commerce or internet commerce, refers to the buying and selling of goods or services using the internet, and the transfer of money and data to execute these transactions. Ecommerce is often used to refer to the sale of physical products online, but it can also describe any kind of commercial transaction that is facilitated through the internet. Whereas e-business refers to all aspects of operating an online business, e-commerce refers specifically to the transaction of goods and services. There are two sections in the whole project. One is Admin another one is Client/Customer. Some features of this project are given below: In the admin section admin can, 1. Login and change password, 2. add, edit, delete, list products category, sub-category, brand, products, etc. 3. Admin can add coupons with the discount amounts. 4. Post different blogs on the site 5. Manage orders 6. Send the newsletter to the subscribed customers 7. Generate different reports 8. Different admin will be added for different specified tasks 9. Capable of changing the site structure for different times 10. do many more things. On the Customers site: 1. Product viewing 2. Order Tracking 3. Login/Registration 4. Profile 5. Header Slider 6. Category 7. Search Product 8. New Feature 9. Deal of Weak 10. Add to cart 11. Product view 12. Coupon 13. Check out 14. And many more things

Tuesday, February 16, 2021

C program to insert an element into an array.

 1
 2
 3
 4
 5
 6
 7
 8
 9
10
11
12
13
14
15
16
17
#include<stdio.h>//Insert Element into Array
int main()
{
        int s = 6;
        int arr[s] = {5, 10, 15, 20, 25, 30}, pos = 2, value = 96, i;

        for(i = s - 1; i >= pos; i--){
                arr[i + 1] = arr[i];
        }
        
        arr[pos] = value;
        for(i = 0; i < s + 1; i++){
                printf("%d\t", arr[i]);
        }
        printf("\n\n");
        return 0;
}