This file contains 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 <cstdio> | |
#include <cstdlib> | |
int main() | |
{ | |
const wchar_t str[] = L"wcstombs example"; | |
char buffer[32]; | |
printf("wchar_t string: %ls \n", str); |
This file contains 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 <cstddef> | |
#include <limits> | |
#include <climits> | |
#include <cfloat> | |
#include <cstdint> | |
#include <cstdlib> | |
#include <new> | |
#include <typeinfo> | |
#include <exception> | |
#include <initializer_list> |
This file contains 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 <cstddef> | |
#include <limits> | |
#include <climits> | |
#include <cfloat> | |
#include <cstdint> | |
#include <cstdlib> | |
#include <new> | |
#include <typeinfo> | |
#include <exception> | |
#include <initializer_list> |
This file contains 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 <vector> | |
using namespace std; | |
typedef struct { | |
int id; | |
const char* name; | |
}INFO; |
This file contains 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
/* strstr test */ | |
/* from http://www.cplusplus.com/reference/cstring/strstr/ */ | |
/* | |
result: | |
address str[10]: 00F1FCB2 | |
address strstr result: 00F1FCB2 | |
address strstr miss: 00000000 | |
*/ | |
#include <stdio.h> | |
#include <string.h> |
This file contains 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
using System; | |
using System.Collections; | |
using System.Collections.Generic; | |
using System.Linq; | |
using System.Text; | |
using System.Threading.Tasks; | |
namespace FactoryMethodPatternTest | |
{ | |
public abstract class Product |
This file contains 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
using System; | |
using System.Collections; | |
using System.Collections.Generic; | |
using System.Linq; | |
using System.Text; | |
using System.Threading.Tasks; | |
namespace FactoryMethodPatternTest | |
{ | |
public abstract class Product |
This file contains 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 <Windows.h> | |
int main() | |
{ | |
std::cout << "Hello World!\n"; | |
//! デフォルトのUnicode使用では文字列が適さない | |
//OutputDebugString("エラー発生!\n"); | |
#ifdef _UNICODE | |
OutputDebugStringA("エラー発生[Unicode]\n"); |
This file contains 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
precision mediump float; | |
uniform float t; // time | |
uniform vec2 r; // resolution | |
const float PI = 3.1415926; | |
const vec2 nosePos = vec2(0.0, 0.1); // 鼻の位置 | |
const vec3 collarColor = vec3(0.95, 0.25, 0.25); // 首輪の色 | |
const vec3 lightColor = vec3(0.95, 0.95, 0.5); // 背景の後光の色 | |
const vec3 backColor = vec3(0.95, 0.25, 0.25); // 背景の下地の色 | |
const vec3 faceColor = vec3(0.00, 0.72, 0.93); // 顔の色 |
This file contains 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 numpy as np | |
import matplotlib.pylab as plt | |
# 4.3.3 | |
# 関数 f(x0, x1) = x0 ** 2 + x1 ** 2 の実装:2変数関数であることに注意 | |
# 引数に numpy 配列を想定 | |
def function_2(x): | |
return x[0] ** 2 + x[1] ** 2 | |
from mpl_toolkits.mplot3d import Axes3D |
NewerOlder