Program of insertion and deletion in B tree
Program of insertion and deletion in B tree
Min Heap C program
#include<stdio.h> #include<conio.h> #include<process.h> int queue[5]; long front,rear; void display(); void main() { int choice,info; clrscr(); //initilisin queue int tqueue(); while(1) { clrscr(); //displaying menu printf(“MENU \n”); printf(“1: insert an element in queue\n”); printf(“2: delete an element from queue\n”); printf(“3: display the queue\n”); printf(“exit!\n”); printf(“your choice:”); scanf(“%i”,&choice); switch(choice) { case 1: if(rear<4) { printf(“enter the no”); scanf(“%d”,&info); if(front==-1) { front=0; rear=0; } else rear=rear+1; queue[rear]=info; } else printf(“queue is full”); break; case 2:int info; if(front!=-1) { info=queue[front]; if(front==rear) { front=-1; rear=-1; } else front=front+1; printf(“no deleted is =%d”,info); } else printf(“queue is empty”); break; case 3: display(); break; case 4: exit(0); break; default: printf(“you entered wrong choice!”); break; } } } void initqueue() { //initilising front & rear to -1 front=rear=-1; } /*displays the current position of the queue*/ void display() { int i; //displaying elements in queue for(i=front;i<=rear;i++) printf(“%i\n”,queue[i]); getch(); }
}
C Program for traversing a tree in Preorder, Postorder and Inorder:
C program for creating your own UNIX Shell:- 🙂
1. Compress the data file u want to hide in a zip file.
2. Open MS-DOS prompt
3. Move to the directory that contains the .rar file and the image you wish to hide the text in.
4. Type a command similar to the below command.
copy /b image_name.jpg + compressed_file_name.rar
5. The process of hiding data is completed
6. Now to get back the file, rename the image file and change its extension to .zip
7. Extract the data file and u r done
Notice the size difference between the normal image and the image containing data.
Hope u like it pls comment if u hav any queries!!!!
This how Hacker send their secret message to another.
C# Web Browser with pop-up blocker:
1). Create a new C# windows application project in Visual Studio.
2). Resize the form to 800×500 px.
3). Drag the following controls from the toolbox(press Ctrl+Alt+X to show toolbox):
a). 1 Buttons (name it as buttonGo)
b). 1 Text Boxes (name it as buttonGo)
c). 1 Microsoft Web Browser
NOTE: We’ll use the activeX web browser control and not the web browser that is directly visible in the toolbox. To get this active web browser control right click on toolbox, select “Choose Toobox Items”, goto COM Components tab, select Microsoft Web Browser and click OK.
5). Arrange all the controls to give your form the following look:
6). Button “Go” is for navigating to the address in the text box on the left to it.
7). Replace “Afact” everywhere in the code below with the name you gave to your application.
8). Write the following code to buttonGo events and NewWindow2 event of the web browser control:
using System;
using System.Collections.Generic;
using System.ComponentModel;
using System.Data;
using System.Drawing;
using System.Linq;
using System.Text;
using System.Windows.Forms;
namespace Afact
{
public partial class Afact : Form
{
public Afact()
{
InitializeComponent();
}
private void Afact_Load(object sender, EventArgs e)
{
axWebBrowser1.Navigate(“www.google.com”);
}
private void buttonGo_Click(object sender, EventArgs e)
{
axWebBrowser1.Navigate(textBoxURL.Text);
}
private void axWebBrowser1_NewWindow2(object sender, AxSHDocVw.DWebBrowserEvents2_NewWindow2Event e)
{
// Is document ready state complete ? If not, that’s an ad popup. Don’t allow it
if (axWebBrowser1.ReadyState != SHDocVw.tagREADYSTATE.READYSTATE_COMPLETE)
{
e.ppDisp = null;
e.cancel = true;
return;
}
/* Else let’s create a new form instance and
send the new web browser instance back to the caller.*/
Afact newwindow = new Afact();
newwindow.Text = “Afact New Window”;
e.ppDisp = newwindow.axWebBrowser1.Application;
newwindow.Show();
}
}
}
Download the project from the BOX on the right side!!!