代码搜索结果
找到约 21,386 项符合
Switch 的代码
switch.c
/*
* Alpha-specific RTLinux switch support
*
* Copyright (C) 2000 Cort Dougan
*/
#include
#include
#include
#include
switch.c
/*
* PPC-specific RTLinux switch support
*
* Copyright (C) 1999 Cort Dougan
*/
#include
#include
#include
#include
switch.java
//: c09:Switch.java
// From 'Thinking in Java, 3rd ed.' (c) Bruce Eckel 2002
// www.BruceEckel.com. See copyright notice in CopyRight.txt.
public class Switch {
private boolean state = false;
switch.c
/* Test the types of switch statement.
type: char, int, long
sign: signed, unsigned
storage: static,
attr: volatile
*/
#include
{sign} {type}
sparseSwitch({sign} {type
switch.c
char x;
/* Valid switch statement */
#ifdef TEST1
char foo(void)
{
switch(x)
{
char y;
case 0:
return 0;
case 1:
return 1;
default:
y = x
lc-switch.h
/*
* Copyright (c) 2004-2005, Swedish Institute of Computer Science.
* All rights reserved.
*
* Redistribution and use in source and binary forms, with or without
* modification, are permitt
source.c
atoi(s) char *s {
int sign, n;
while(isspace(*s)) ++s;
sign = 1;
switch(*s) {
case '-': sign = -1;
case '+': ++s;
}
n = 0;
while(isdigit(*s)) n = 10 * n + *s++ - '0
source.c
atoi(s) char *s {
int sign, n;
while(isspace(*s)) ++s;
sign = 1;
switch(*s) {
case '-': sign = -1;
case '+': ++s;
}
n = 0;
while(isdigit(*s)) n = 10 * n + *s++ - '0
zv-snd
#!/bin/sh
amixer eset 'ZV Port Switch',0,Switch2 on >/dev/null
amixer eset 'FM Input Switch',0,Switch1 on >/dev/null
amixer eset 'FM Input Volume',0,Volume1 30% >/dev/null
基本语法.txt
条件分支
if(条件)
{
语句1
}
else
{
语句2
}
switch(条件)
{
case 0:语句1;break;
case 1:语句2;break;
...
case n:语句n;break;
default:语句n+1;break;
}
循环
for(初始化部分(可选);i