prompt() 可以弹出一个提示框,该提示框中会带有一个文本框, 用户可以在文本框中输入一段内容,该函数需要一个字符串作为参数, 该字符串将会作为提示框的提示文字 用户输入的内容将会作为函数的返回值返回,可以定义一个变量来接受该内容 switch……case……语句 在执行时会依次将case后的表 ...
分类:
Web程序 时间:
2020-07-20 22:33:59
阅读次数:
110
1 #include<windows.h> 2 #include<iostream> 3 #include<string> 4 using namespace std; 5 int stop=500; 6 int getFreq(char key){ 7 int freq=0; 8 switch(k ...
分类:
编程语言 时间:
2020-07-19 00:56:58
阅读次数:
143
package com.cx.Switch; import java.util.Scanner; /** * 计算出某年某月某日是今年的第几天 * 使用switch */ public class SwitchDemo { public static void main(String[] args) ...
分类:
其他好文 时间:
2020-07-19 00:45:16
阅读次数:
130
int romanToInt(char * s){ int count = 0; while (*s) { switch(*s) { case 'I': if (*(s+1) == 'V' || *(s+1) == 'X') count -= 1; else count += 1; break; c ...
分类:
其他好文 时间:
2020-07-19 00:43:57
阅读次数:
74
给Xcode命令行工具指定路径 sudo xcode-select --switch /Applications/Xcode.app 其他命令参考 $ sudo xcode-select --switch /Applications/Xcode.app/Contents/Developer/ //查 ...
分类:
其他好文 时间:
2020-07-18 15:36:16
阅读次数:
87
1、流程控制 通过控制代码的执行顺序来实现我们完成的功能,js中流程控制有三种结构 顺序结构:按照代码的先后顺序,依次执行 分支结构:根据不同的条件执行不同的代码,如:if和switch... ...case语句 循环结构:while、do.. ...while、for、break、continue ...
分类:
Web程序 时间:
2020-07-17 13:35:06
阅读次数:
81
react-router-dom V5 使用指南(1) react-router 提供了路由核心接口,如 Router、Route、Switch 等,未提供终端操作相关的接口; react-router-dom 提供了浏览器端接口,BrowserRouter、HashRouter,Route、Lin ...
分类:
其他好文 时间:
2020-07-17 09:20:23
阅读次数:
90
1、算术运算符 算数运算符 说明 例子 + 加法 10 + 3 = 13 - 减法 10 - 3 = 7 * 乘法 10 * 3 = 30 / 除法 12 / 3 = 4 % 求余(求模) 10 % 3 = 1 ++ 自增1 int i = 0;i++ -- 自减1 int i = 0;i-- 注意 ...
分类:
编程语言 时间:
2020-07-16 21:34:12
阅读次数:
94
MapReduce: Simplified Data Processing on Large Clusters MapReduce是什么? a programming model and an associated implementation for processing and generati ...
分类:
其他好文 时间:
2020-07-16 10:13:57
阅读次数:
73
语法: switch(表达式){ //表达式为 int、short、byte、char、枚举、String类型 case常量1: //计算表达式的值 语句; //如果等于常量1 break; case常量2: 语句; //如果等于常量2 break; …… default: 语句; //如果没有找到 ...
分类:
其他好文 时间:
2020-07-15 23:56:21
阅读次数:
96