@amannarayanm

Implementation Circular Queue using ARRAY

updated October 20, 2021 · C
#include <stdio.h>
#include <stdlib.h>

struct Queue{
  int size;    
  int f;
  int r;
  int *arr;
};

void traversal(struct Queue *q){

single Inheritance in PYTHON

October 18, 2021 · Python
# base class

class university:
    university_name = "Mumbai University"
    def myfun(self):
        print("\nHello This is Base Class")


class college(university):
    College_name = "Saket College Arts, Science and Commerce"
    def myfoo(self):
#include <stdio.h>
#include <stdlib.h>

struct Queue{
  int size;
  int front;
  int rear;
  int *arr;
};

void traversal(struct Queue *ptr){

Conversion of Infix to postfix using STACK

updated October 14, 2021 · C
#include<stdio.h>
#include<stdlib.h>
#include<string.h>

struct stack {
  int top;
  int size;
  char *arr;
};

int isFull(struct stack *ptr){

Implementation of Stack using LinkedList

updated October 13, 2021 · C
#include <stdio.h>
#include <stdlib.h>

struct node{
    int data;
    struct node *next;
};

int isFull(){
    struct node* ptr;
    ptr = (struct node*)malloc(sizeof(struct node));
#include <stdio.h>
#include <stdlib.h>

struct node {
  int top;
  int size;
  char *arr;
};

int isEmpty(struct node *ptr){
    if(ptr->top == -1){
#include <stdio.h>
#include <stdlib.h>

struct node {
  int top;
  int size;
  char *arr;
};

int isEmpty(struct node *ptr){
    if(ptr->top == -1){

Class creation Basic

October 12, 2021 · Python
class student:
    College = "Saket College Arts science and Commerce"
    def __init__(self,name,Class):
        self.name = name
        self.Class = Class
    def getyourDetails(self):
        print(f"\nName: {self.name}\nClass: {self.Class}\nCollege: {self.College}")
        
        
s1 = student("Aman Mishra","3rd Semester BSC-IT")
s1.getyourDetails()

Implementation of stack using Linked List

updated October 12, 2021 · C
#include <stdio.h>
#include <stdlib.h>

struct node{
  int data;
  struct node* next;
};

int isEmpty(struct node* sp){
    if(sp == NULL){
        return 1;
#include<stdio.h>
#include<stdlib.h>

struct stack{
    int top;
    int size;
    int *arr;
};

int isFull(struct stack *ptr)
{

STACK IMPLEMENTATION

October 09, 2021 · C
#include <stdio.h>
#include <stdlib.h>

struct stack{
  int top;
  int size;
  int *arr;
};

int isFull(struct stack *ptr)
{
#include <stdio.h>
#include<stdlib.h>

void traversal(int arr[],int size)
{
    for(int i=0;i<size;i++)
    {
        printf("%d ",arr[i]);
    }
    printf("\n");
}

Insert the element in an array

September 29, 2021 · C++
#include <iostream>
using namespace std;

void traversal(int arr[],int size)
{
    for(int i=0;i<size;i++)
    {
        cout<<arr[i]<<" ";
    }
    cout<<endl;
}
#include <stdio.h>
#include<stdlib.h>

struct node{
    int data;
    struct node * next;
};

void linkedList_Traversal(struct node *ptr)
{
    while(ptr != NULL)
def remove_Split(string,word):
    string =string.replace(word,"")
    print(string.strip())


sentence = "        Happy New Year buddy       "


remove_Split(sentence,"buddy")
def reversed_Array(num):
    for i in reversed(range(1,11)):
        print(str(num)+" X ",i,"=",num*i)

reversed_Array(5)
def inches_to_cms(num):
    print("Length in Centi_Meter:",num*2.45)
    
inches_to_cms(1)
inches_to_cms(5)
def pattern(n):
    for i in range(1,n+1):
        for j in reversed(range(i,n+1)):
            print("X",end="")
        print()
    
    
pattern(10)
def sum(num):
    if num==1 or num==0:
        return 1
    else:
        sum_number = num + sum(num-1)
    return sum_number
    
    
print(sum(10))
#  Before using technique for print function

print("Jai Shree Ram")
print("Jai Shree Ram")

#  After using technique for print function

print("jai Shree Krishna",end=" ")
print("Jai Shree Krishna")