- DP for beginners by @wh0ami - https://leetcode.com/discuss/general-discussion/662866/dp-for-beginners-problems-patterns-sample-solutions || [LIST - https://leetcode.com/list/x1k8lxi5]
- Graph for beginners by @wh0ami - https://leetcode.com/discuss/general-discussion/655708/graph-for-beginners-problems-pattern-sample-solutions/562734 || [LIST - https://leetcode.com/list/x1wy4de7]
- Sliding window for beginners by @wh0ami - https://leetcode.com/discuss/general-discussion/657507/sliding-window-for-beginners-problems-template-sample-solutions/562721 || [LIST - https://leetcode.com/list/x1lbzfk3]
- DP Patterns by @aatalyk - https://leetcode.com/discuss/general-discussion/458695/dynamic-programming-patterns Leetcode patterns from edu_cative_dot_io by @late_riser - https://leetcode.com/discuss/general-discussion/457546/LeetCode-Problem-Patterns-from-***
- List of questions sorted by common patterns by @Maverick2594 - https://leetcode.com/discuss/career/448285/List-of-q
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<conio.h> | |
| #define SZ 20 | |
| int k; | |
| main() | |
| { | |
| int i,j,m ,F; | |
| int e[3],a[SZ][SZ],t[SZ][SZ],x[3],n; | |
| printf("This program is for 2 line and maximum 20 station at each line.\n"); | |
| printf("Enter number of station \n"); |
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<string.h> | |
| #include "mpi.h" | |
| int main(int argc,char *argv[]) | |
| { | |
| int my_rank; | |
| int p; | |
| int source; | |
| int dest; |
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<string.h> | |
| #include "mpi.h" | |
| int main(int argc,char* argv){ | |
| int rnk,src,dest=0,tag=0,p; | |
| char mesg[100010]; | |
| MPI_Status stat; | |
| MPI_Init(&argc,&argv); | |
| MPI_Comm_rank(MPI_COMM_WORLD,&rnk); | |
| MPI_Comm_size(MPI_COMM_WORLD,&p); |
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> | |
| #define REP(i,a,b) for(i=a;i<=b;i++) | |
| using namespace std; | |
| int main(){ | |
| string plain,cipher=""; | |
| int i,n,key; | |
| cin>>plain>>key; | |
| n=plain.length(); | |
| REP(i,0,n-1){ | |
| cipher+=char((plain[i]-'a'+key)%26+'a'); |
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
| /* | |
| ****************************************************************** | |
| ** Advanced Encryption Standard implementation in C. ** | |
| ** By Niyaz PK ** | |
| ** E-mail: niyazlife@gmail.com ** | |
| ** Downloaded from Website: www.hoozi.com ** | |
| ****************************************************************** | |
| This is the source code for encryption using the latest AES algorithm. | |
| AES algorithm is also called Rijndael algorithm. AES algorithm is | |
| recommended for non-classified by the National Institute of Standards |
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
| import socket | |
| HOST = '' | |
| PORT = 56231 | |
| address_family = socket.AF_INET | |
| socket_type = socket.SOCK_STREAM | |
| request_queue_size = 1 |
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> | |
| #include<string.h> | |
| int a[20][257],nodes[200],stack[200],top; | |
| void push(int a) | |
| { | |
| stack[top]=a; | |
| top++; |
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
| set ns [new Simulator] | |
| set f [open out.tr w] | |
| $ns trace-all $f | |
| setnf [open out.nam w] | |
| $ns namtrace-all $nf | |
| set n0 [$ns node] | |
| set n1 [$ns node] | |
| $ns duplex-link $n0 $n1 1Mb 10ms DropTail | |
| set udp0 [new Agent/UDP] | |
| $ns attach-agent $n0 $udp0 |
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 <GL/glut.h> | |
| #include <stdio.h> | |
| #include <math.h> | |
| #include <stdlib.h> | |
| int h,k; | |
| float a,b; | |
| void display(void) | |
| { | |
| double I,J; | |
| int i,j; |
NewerOlder