This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#include<bits/stdc++.h> | |
using namespace std; | |
struct circullerqueue | |
{ | |
int a[10]; | |
int SIZE=0; | |
int MAX_ELEMENT=10; | |
int Front=-1,rear=-1; | |
void push(int data) |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#include<bits/stdc++.h> | |
using namespace std; | |
template<typename T> | |
struct linkedlist | |
{ | |
T data; | |
linkedlist *next; | |
}; |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#include<bits/stdc++.h> | |
using namespace std; | |
struct linkedlist | |
{ | |
int data; | |
linkedlist *next; | |
} *root; | |
void appand(int newdata) |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#include<stdio.h> | |
#include<stdlib.h> | |
#define NULL_VALUE -99999 | |
#define SUCCESS_VALUE 99999 | |
struct listNode | |
{ | |
int item; |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#include<stdio.h> | |
#include<stdlib.h> | |
#define NULL_VALUE -99999 | |
#define SUCCESS_VALUE 99999 | |
struct listNode | |
{ | |
int item; |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#include<stdio.h> | |
#include<stdlib.h> | |
#define NULL_VALUE -99999 | |
#define SUCCESS_VALUE 99999 | |
struct listNode | |
{ | |
int item; |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#include<bits/stdc++.h> | |
using namespace std; | |
int StringToNumber ( const char *c ) | |
{ | |
int r=0; | |
int k=0; | |
for(int i=strlen(c)-1; i>=0; i--) | |
{ | |
r+=((c[i]-'0')*((int)pow(10,k))); |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#include<bits/stdc++.h> | |
using namespace std; | |
int inf=INT_MAX; | |
vector< pair<int,int> >edge; | |
int w[205][205]; | |
int b[205]; | |
int dist[205]; | |
int n,m; |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#include<bits/stdc++.h> | |
using namespace std; | |
#define mx 505 | |
long long matrix[mx][mx]; | |
int main() | |
{ | |
memset(matrix,INT_MAX,sizeof matrix); |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#include <bits/stdc++.h> | |
using namespace std; | |
#define pii pair<int,int> | |
#define pb push_back | |
#define INF 0x7fffffff | |
#define sz 100005 | |
priority_queue<pii,vector<pii>,greater<pii> >q; | |
vector<pii>G[sz]; | |
int dist[sz]; | |
bool vis[sz]; |