最終行から上に向かってサーチする方法
ThisWorkbook.Sheets(“SheetName”).Range(“A65536″).End(xlUp).Row
Just another WordPress site
最終行から上に向かってサーチする方法
ThisWorkbook.Sheets(“SheetName”).Range(“A65536″).End(xlUp).Row
#include <windows.h>
int main()
{
HANDLE hFind;
WIN32_FIND_DATA win32fd;
hFind = FindFirstFile("C:\\*.*", &win32fd);
if (hFind == INVALID_HANDLE_VALUE) {
return 1;
}
do {
if (win32fd.dwFileAttributes & FILE_ATTRIBUTE_DIRECTORY) {
printf("%s (DIR)\n", win32fd.cFileName);
} else {
printf("%s\n", win32fd.cFileName);
}
} while (FindNextFile(hFind, &win32fd));
FindClose(hFind);
return 0;
}
短くて効果的な感じなやつ
mt_srand(crc32(microtime()));
最近は普通のsrandよりもmt_のついている方を
使用するのが一般的らしい。
randも同じみたいで、より高速なのだとか。
#include <vector>
#include <iostream>
int main()
{
using namespace std;
vector<int> array;
int i;
for( i = 0; i < 10; ++i )
{
array.push_back( i );
}
vector<int>::iterator it = array.begin(); // イテレータのインスタンス化
while( it != array.end() ) // 末尾要素まで
{
cout << *it << endl; // *演算子で間接参照
++it; // イテレータを1つ進める
}
return 0;
}