Skip to content

Instantly share code, notes, and snippets.

View JeonghunLee's full-sized avatar
🤗
I may be slow to respond.

JeongHun (James) Lee JeonghunLee

🤗
I may be slow to respond.
View GitHub Profile
#include<stdio.h>
//Jeonghun Lee, this is first test code.
int main()
{
printf ("Test Github1 , gist test ");
return 0;
}
#include<stdio.h>
//Jeonghun Lee, this is second test code.
int main()
{
printf ("Test Github1 , gist test ");
return 0;
}
// blogspot test 용 입니다.
#include<stdio.h>
int main()
{
printf(" blogspot test 용 입니다. \n");
return 0;
}
#include <stdio.h>
#include <stdlib.h>
typedef struct ListElmt_ {
void * data;
struct ListElmt_ *next;
}ListElmt;
typedef struct List_ {
#include <stdio.h>
#define MAX 10
int size=0;
int head=0; // not used in stack
int tail=0;
int queue[MAX];
int stack[MAX];
/*
Quick sort example 3
*/
#include <stdio.h>
//SETTING QUICK SORT, PIVOT POSITION
#define PIVOT_LEFT
//#define PIVOT_RIGHT
#include <stdio.h>
// general recursion
int factorial(int n)
{
if(n==0)
return 1;
else
return n * factorial(n-1);
}
#include <stdio.h>
#include <string.h>
int getStrlens(char str[])
{
int cnt=0;
while(str[cnt] !='\0')
cnt++;
#include <stdio.h>
//refer to https://ko.wikipedia.org/wiki/%ED%9E%99_%EC%A0%95%EB%A0%AC
#define heap_parent(n) ((n-1)/2)
#define heap_left(n) ((2*n)+1)
#define heap_right(n) ((2*n)+2)
typedef enum{
SET_HEAPNULL=0,
SET_UPHEAP,
#include <stdio.h>
/*
refer to
http://www.thecrazyprogrammer.com/2014/03/depth-first-search-dfs-traversal-of-a-graph.html
*/
#define MAX_MAPSIZE 50
#define SET_UNDIRECTIED_GRAPH
int map[MAX_MAPSIZE][MAX_MAPSIZE]={0}; //