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
// shift.cpp | |
// code from MSDN | |
// Demonstrate shift operators | |
#include <iostream> | |
using namespace std; | |
int _tmain() { | |
cout << "5 times 2 is " << (5 << 1) << endl; // 5 × 2 = 10 |
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
// SimpleClient.cpp | |
#include "ace/ACE.h" | |
#include "ace/INET_Addr.h" | |
#include "ace/SOCK_Connector.h" | |
#include "ace/SOCK_Stream.h" | |
int main() | |
{ | |
const char* pathname = "index.html"; |
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
// MinMax.cpp | |
// min/max value of C++ | |
// code from : http://www.cppreference.com/wiki/data_types | |
#include <limits> | |
std::cout << "Maximum short value: " << std::numeric_limits<short>::max() << std::endl; | |
std::cout << "Minimum short value: " << std::numeric_limits<short>::min() << std::endl; | |
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
// get_libc_ver.cpp | |
// http://j2doll.tistory.com/467 | |
#include <stdio.h> | |
#include <gnu/libc-version.h> | |
int main (int argc, char* argv[]) | |
{ | |
puts (gnu_get_libc_version ()); | |
return 0; |
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
// Project1.cpp | |
//--------------------------------------------------------------------------- | |
#include <vcl.h> // VCL 사용 시, 기본은 이거... | |
#pragma hdrstop // 프리컴파일러 최적화 ; #include 처리 후에 써 준다... | |
USEFORM("Unit1.cpp", Form1); // 매크로 ; 폼을 사용한다는 매크로이겄슴... | |
WINAPI WinMain(HINSTANCE, HINSTANCE, LPSTR, int) // entry point | |
{ |
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
// which32-64.cpp | |
// check 32/64bit for Microsoft Visual C++(Visual Studio) (or, C++ Builer, etc) | |
#if ((ULONG_MAX) == (UINT_MAX)) | |
# define IS32BIT // 32bit Windows(x32) | |
#else | |
# define IS64BIT // 64bit Windows(x64) | |
#endif | |
// check 32/64bit for gcc(g++) |
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
// qt.single.instance.cpp | |
// | |
// code from http://blog.naver.com/PostView.nhn?blogId=browniz1004&logNo=220957590867&categoryNo=15&parentCategoryNo=0&viewDate=¤tPage=8&postListTopCurrentPage=&from=postList&userTopListOpen=true&userTopListCount=5&userTopListManageOpen=false&userTopListCurrentPage=8 | |
#include "mainwindow.h" | |
#include <QApplication> | |
#include <QSharedMemory> | |
int main(int argc, char *argv[]) | |
{ |
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 <windows.h> | |
int APIENTRY _tWinMain(HINSTANCE hInstance,HINSTANCE hPrevInstance,LPTSTR lpCmdLine,int nCmdShow) | |
{ | |
UNREFERENCED_PARAMETER(hPrevInstance); | |
UNREFERENCED_PARAMETER(lpCmdLine); // warning is not displayed | |
// ... |
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 <xlnt/xlnt.hpp> | |
int main() | |
{ | |
xlnt::workbook wb; | |
wb.load("/home/timothymccallum/test.xlsx"); | |
auto ws = wb.active_sheet(); | |
std::clog << "Processing spread sheet" << std::endl; | |
for (auto row : ws.rows(false)) |
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 <xlnt/xlnt.hpp> | |
#include <vector> | |
int main() | |
{ | |
xlnt::workbook wb; | |
wb.load("/home/timothymccallum/test.xlsx"); | |
auto ws = wb.active_sheet(); | |
std::clog << "Processing spread sheet" << std::endl; |