⭐ 欢迎来到虫虫下载站! | 📦 资源下载 📁 资源专辑 ℹ️ 关于我们
⭐ 虫虫下载站

📄 strutils.h

📁 C++&datastructure书籍源码,以前外教提供现在与大家共享
💻 H
字号:
#ifndef _STRUTILS_H#define _STRUTILS_H#include <iostream>#include <string>using namespace std;void ToLower(string & s);// postcondition: all alphabetic characters in s changed to lowercase//                (only uppercase letters changed)void ToUpper(string & s);// postcondition: all alphabetic characters in s changed to uppercase//                (only uppercase letters changed)void StripPunc(string & s);// postcondition: s has no leading/trailing punctuationvoid StripWhite(string & s);// postcondition: s has no leading/trailing white spacestring LowerString(const string & s);// postcondition: return lowercase equivalent of sstring UpperString(const string & s);// postcondition: return uppercase equivalent of sint atoi(const string & s);         // returns int equivalentdouble atof(const string & s);      // returns double equivalentstring itoa(int n);                 // returns string equivalentstring tostring(int n);             // like itoa, convert int to stringstring tostring(double d);          // convert double to string    #endif 

⌨️ 快捷键说明

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