Tuesday 13 December 2016

Data Structure & Algorithms | Queue

 DATA STRUCTURE

QUEUE

Queue is an abstract data structure, somewhat similar to Stacks. Unlike stacks, a queue is open at both its ends. One end is always used to insert data (enqueue) and the other is used to remove data (dequeue). Queue follows First-In-First-Out methodology, i.e., the data item stored first will be accessed first.

#include<stdio.h>
#include<stdlib.h>
#define Max 5
int a[Max];
int rear=-1;
int front=-1;
void insert(int);
void delete();
void display();
void main()
{
    int c,item;
    do
    {
        printf("\nPress 1:Insert\nPress 2:Delete\nPress 3:Diplay\nPress 0:Exit\n");
        scanf("%d",&c);
        switch(c)
        {
            case 1:printf("Enter Element\n");
                    scanf("%d",&item);
                    insert(item);
                    break;
            case 2:delete();
                    break;
            case 3:display();
                    break;
            case 0:exit(0);
        }
    }while(1);
}
void insert(int item)
{
    if(rear==Max-1)
    printf("Insertion not Possible\n");
    else
    {
        rear++;
        a[rear]=item;
    }
}
void delete()
{
    if(rear==front)
    printf("Deletion not Possible\n");
    else
    {
        front++;
        printf("Deleted Element %d",a[front]);
    }
}
void display()
{
    int i;
    printf("Queue :");
    for(i=front+1;i<=rear;i++)
    printf("%d ",a[i]);
}

,Thanks
Bikki Mahato

Friday 9 December 2016

Canon Combo of PG-88 Fine And CL-98 Ink Cartridge (PG-88 Black:CL-98 Color)

Buy this amazing canon combo ink cartridges, i.e , PG-88 Black , CL-98 Color

Features:-

  • Canon CL-98 Ink Cartridge is compatible with Pixma E510 / E610
  • Canon PG-88 ink cartridge is compatible with the Pixma E 500 and E 600 printer
  • Color Type : PG 88- Black, CL 98- Color
  • Cartridge breathes life into every print, high-quality make and diligent performance
  • Package content: 2 ink cartridge 



Buy from the link below to get discounts and cashbacks!!!
http://amzn.to/2ha08uH

Technical Details:-

BrandCanon
ColourTri-color
Item Height10 Centimeters
Item Width10 Centimeters
Item Weight141 g
Product Dimensions10 x 10 x 10 cm
Item part numberCNNCMB_88_98-02


Sunday 6 November 2016

Data Structure & Algorithms | Stack

DATA STRUCTURE

STACK

A stack is a basic data structure that can be logically thought as linear structure represented by a real physical stack or pile, a structure where insertion and deletion of items takes place at one end called top of the stack. The basic concept can be illustrated by thinking of your data set as a stack of plates or books where you can only take the top item off the stack in order to remove things from it. This structure is used all throughout programming.
The basic implementation of a stack is also called a LIFO (Last In First Out) to demonstrate the way it accesses data, since as we will see there are various variations of stack implementations.
There are basically three operations that can be performed on stacks . They are 1) inserting an item into a stack (push). 2) deleting an item from the stack (pop). 3) displaying the contents of the stack(pip).

#include<stdio.h>
#include<stdlib.h>
#define Max 5
int a[Max];
int top=-1;
void push(int);
void pop();
void display();
void main()
{
    int c,item;
    do
    {
        printf("Press 1:Push\nPress 2:Pop\nPress 3:Display\nPress 4:Exit\n");
        scanf("%d",&c);
        switch(c)
        {
            case 1:printf("Enter Element\n");
                    scanf("%d",&item);
                    push(item);
                    break;
            case 2:pop();
                    break;
            case 3:display();
                    break;
            case 4:exit(0);
        }
    }while(1);
}
void push(int item)
{
    if(top==Max-1)
    printf("\nStack is Full");
    else
    {
        top++;
        a[top]=item;
    }
}
void pop()
{
    if(top==-1)
    printf("\nStack is Empty");
    else
    {
        printf("\nDeleted Element %d",a[top]);
        top--;
    }
}
void display()
{
    int i;
    printf("Stack : ");
    for(i=top;i>=0;i--)
    printf("%d ",a[i]);
    printf("\n");
}

,Thanks
Bikki Mahato

 

Wednesday 1 June 2016

Maximum Power Transfer Theorem

In this video lecture we will learn about maximum power transfer theorem , its statement , its proof and its examples.


,Thanks
Bikki Mahato

Superposition Theorem

In this video lecture we will learn about superposition theorem, its procedure and see some example.
,Thanks
Bikki Mahato

Mesh Analysis (or Loop Analysis)

In this video lecture we will learn about mesh analysis its procedure and see how it works with the help of example.
,Thanks
Bikki Mahato

Nodal Analysis

In this video we will learn about Nodal Analysis and discuss its procedure with the help of example.
,Thanks
Bikki Mahato

Monday 25 April 2016

Kirchhoff's Current Law & Kirchhoff's Voltage Law

In this video lecture we will learn about Kirchhoff's Laws, Kirchhoff's Current law and Kirchhoff's Voltage law.


,Thanks
Bikki Mahato

Voltage Divider and Current Divider

In this video lecture I will show how to use voltage divider rule and current divider rule.


,Thanks
Bikki Mahato

Infinite Series- 15 Alternating Series- Absolute Convergence, Conditional Convergence

In this video lecture we will be learning about absolute and conditional convergence of an alternating infinite series.


,Thanks
Bikki Mahato

Infinite Series- 14 Alternating Series- Leibniz's Test

In this video lecture we will learn about Leibniz's Test for convergence of an alternating series with the help of example.


,Thanks
Bikki Mahato

Infinite Series- 13 Alternating Series

In this video lecture we will learn about infinite series, alternating series is discussed with the help of examples.


,Thanks
Bikki Mahato

Infinite Series- 12 Raabe's Test

In this video lecture we will learn about Raabe's test and its use with the help of example.


,Thanks
Bikki Mahato