scilab: test enum example, source renamed
This commit is contained in:
parent
bf2a71ec7d
commit
7c1899a458
3 changed files with 24 additions and 1 deletions
|
|
@ -1,16 +0,0 @@
|
|||
/* File : example.c */
|
||||
|
||||
#include "example.h"
|
||||
#include <stdio.h>
|
||||
|
||||
void enum_test(color c) {
|
||||
if (c == RED) {
|
||||
printf("color = RED\n");
|
||||
} else if (c == BLUE) {
|
||||
printf("color = BLUE\n");
|
||||
} else if (c == GREEN) {
|
||||
printf("color = GREEN\n");
|
||||
} else {
|
||||
printf("color = Unknown color!\n");
|
||||
}
|
||||
}
|
||||
Loading…
Add table
Add a link
Reference in a new issue