functions.cpp

来自「一个将binary转化为cpp的转换程序」· C++ 代码 · 共 39 行

CPP
39
字号
/*************************************************************************** *  Filename :  functions.cpp *  Started  :  10/22/04 *  Copyright:  (C) 2004 Christian Petri *  Email    :  viperb0y@users.sourceforge.net * * *  This program is free software; you can redistribute it and/or modify *  it under the terms of the GNU General Public License as published by *  the Free Software Foundation; either version 2 of the License, or *  (at your option) any later version. * **************************************************************************/#include "functions.h"long int filesize(char *fp){  ifstream infilesize(fp, ios_base::in);  if (infilesize)  {    infilesize.seekg(0L, ios_base::end);    return infilesize.tellg();  } else {    return 1;  } }string strtoupper(string s){  transform(s.begin(), s.end(), s.begin(), static_cast<int(*)(int)>(toupper));  return s;}

⌨️ 快捷键说明

复制代码Ctrl + C
搜索代码Ctrl + F
全屏模式F11
增大字号Ctrl + =
减小字号Ctrl + -
显示快捷键?