Skip to content

Instantly share code, notes, and snippets.

View lehaiquantb's full-sized avatar
👌

QuanLe lehaiquantb

👌
View GitHub Profile
@lehaiquantb
lehaiquantb / BaiTap1.cpp
Created March 16, 2020 20:21
Network Programming LeHaiQuan20173316
#include <stdio.h>
#define _WINSOCK_DEPRECATED_NO_WARNINGS
#include <winsock2.h>
#include <ws2tcpip.h>
#pragma comment(lib, "ws2_32")
//Hàm kiểm tra tên miền
@lehaiquantb
lehaiquantb / LinearLayout-caculator
Last active March 25, 2020 12:10
Android Homework
<?xml version="1.0" encoding="utf-8"?>
<LinearLayout xmlns:android="http://schemas.android.com/apk/res/android"
xmlns:app="http://schemas.android.com/apk/res-auto"
xmlns:tools="http://schemas.android.com/tools"
android:layout_width="match_parent"
android:layout_height="match_parent"
android:orientation="vertical"
tools:context=".MainActivity">
#include <stdio.h>
#include<iostream>
#define _WINSOCK_DEPRECATED_NO_WARNINGS
#include <winsock2.h>
#include <ws2tcpip.h>
#pragma comment(lib, "ws2_32")
using namespace std;
#include <iostream>
#include <windows.h>
CRITICAL_SECTION cs;
using namespace std;
static long num_steps = 1000000;
double step, pi;
double sum = 0.0;
@lehaiquantb
lehaiquantb / chat-server.cpp
Last active April 10, 2020 02:12
BT tuan 32
// tuan32b1_chatserver.cpp : This file contains the 'main' function. Program execution begins and ends there.
//
#include <stdio.h>
#include <winsock2.h>
#include<iostream>
#include<string>
#include<map>
using namespace std;
@lehaiquantb
lehaiquantb / tuan33_chatserver.cpp
Last active April 17, 2020 08:56
Tuan 33 - Using select to create chatserver, telnetserver
// tuan32b1_chatserver.cpp : This file contains the 'main' function. Program execution begins and ends there.
//
#include <stdio.h>
#include <winsock2.h>
#include<iostream>
#include<string>
#include<map>
using namespace std;
@lehaiquantb
lehaiquantb / tuan7_chatserver_model.cpp
Last active April 24, 2020 08:41
Chatserver model using socket mutilthread
// ChatServer.cpp : This file contains the 'main' function. Program execution begins and ends there.
//
#include <stdio.h>
#include <winsock2.h>
#include <iostream>
#include<string>
#include<vector>
@lehaiquantb
lehaiquantb / WSAsyncSelect_ChatServer.cpp
Created May 1, 2020 08:29
ChatServer and TelnetServer using WSAsyncSelect
#include <stdio.h>
#define _WINSOCK_DEPRECATED_NO_WARNINGS
#include <winsock2.h>
#include<iostream>
#include<string>
#include<map>
#define WM_SOCKET WM_USER + 1
@lehaiquantb
lehaiquantb / multiple_ssh_setting.md
Last active June 14, 2022 17:21 — forked from jexchan/multiple_ssh_setting.md
Multiple SSH keys for different github accounts

Multiple SSH Keys settings for different github account

create different public key

create different ssh key according the article Mac Set-Up Git

$ ssh-keygen -t rsa -C "[email protected]"