random int, double, char, string => byte
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> | |
/** | |
* swap function | |
* @param xp pointer x | |
* @param yp pointer y | |
* */ | |
void swap(long *xp, long *yp) { | |
// define temporary values | |
long temp0 = *xp; |
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
/** | |
* compute RTT values | |
* (DevRTT, EstimatedRTT, TimeoutInterval) | |
* @author shj <https://github.com/Gumball12> | |
* */ | |
// import module | |
#include <stdio.h> | |
#include <stdlib.h> // for absolute value function 'abs' |
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
/** | |
* tcp socket programming (client-side) | |
* @author shj | |
*/ | |
// import module | |
const net = require('net'); | |
// create TCP socket | |
const client = new net.Socket(); |
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
// cs-assignment 2-4 "Byte Manipulation - Integer Addition" | |
// @author shj | |
// import modules | |
#include <stdio.h> | |
#include <limits.h> // for get limits the values of various variable types | |
/** | |
* integer addition with unsigned short int type | |
* @param a first operand |
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
// cs-assignment 2-2 "Byte Manipulation - Byte Level Operation" | |
// @author shj | |
// import modules | |
#include <stdio.h> | |
#include <stdlib.h> | |
#include <time.h> | |
#define STR_SIZE 10 // string size | |
#define TESTING_TIMES 30 // for unit-testing |
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
// https://rextester.com/KAY13591 | |
// import modules | |
#include <iostream> | |
// define Character class | |
class Character { | |
private: | |
// declare fields | |
int x; |
-
refλ μΈμ λ κΌ λ¬μ => μ λ’°μ± λμμ§
- κΌ ref λ¬ λ μλλΌλ κ΅μ₯ν μ μ©ν μ 보λ€μ μ»μ μ μμλ―
-
ref κ²μλ°©λ²
- λμκ΄ ννμ΄μ§ (μμΌλ©΄ μ문볡μ¬μ μ²)
- λμκ΄μ ν΅ν©κ²μ (κ°μ’μλ―)
- λ¬Όλ‘ ν΄μΈ μλ£λ κ°λ₯
- νμ DB (RISS, NDSL, κ΅νλμκ΄)
- λμκ΄ ννμ΄μ§ ν΅ν΄μ κ°λ©΄ λ¨. νκ΅μμ ꡬ맀ν μ λ£μλ£ λ³Ό μ μκΈ° λλ¬Έ
- λμκ΄ ννμ΄μ§ (μμΌλ©΄ μ문볡μ¬μ μ²)
-
λ¬Όλ‘ κ΅¬λ§€μν μλ£λ μκΈ°μ, μ문볡μ¬μ μ²
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 modules | |
#include <stdio.h> | |
#include <limits.h> | |
#include <stdlib.h> | |
// define Stack struct | |
struct Stack { | |
int* arr; | |
int top; | |
unsigned length; |
image url: https://i.imgur.com/KcWJN4n.png