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 <iostream> | |
#include <boost/asio.hpp> | |
class Contextable { | |
public: | |
Contextable(boost::asio::io_context& ctx) : m_ioContext(ctx) {} | |
protected: | |
boost::asio::io_context& m_ioContext; | |
}; |
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
#!/usr/bin/env python | |
import random | |
secret_number = random.randint(0, 100) | |
guesses = 0 | |
number = 0 | |
while "The input number is incorrect": | |
number = input("Take your guess: ") | |
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
/* gcc -o test-pem test-pem.c -lssl -lcrypto */ | |
#include <stdio.h> | |
#include <stdlib.h> | |
#include <openssl/pem.h> | |
int main(int argc, char* argv[]) { | |
FILE *fp = NULL; | |
EVP_PKEY* key = NULL; |
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
x=input()+1 | |
while 1: | |
if(all(x%j for j in range(2,int(x**.5)+1))):print([x,2][x==1]);break | |
x+=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 <time.h> | |
#define MIN 1 | |
#define MAX 100 | |
/** | |
* @brief Pick up a random number between @p min and @p max. |
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
#!/usr/bin/env python3 | |
_HANDLERS = {} | |
def handle(key): | |
def wrapper(func): | |
_HANDLERS[key] = func | |
return wrapper |
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> | |
#include <stdint.h> | |
#include <tls.h> | |
int main(int argc, char** argv) { | |
char buf[8192]; | |
tls_init(); |
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> | |
#include <stdint.h> | |
#include <tls.h> | |
int main(int argc, char** argv) { | |
char buf[8192]; | |
tls_init(); |