This repository has been archived on 2023-10-26. You can view files and clone it, but cannot push or open issues or pull requests.
VSMechatronics/Lectures/LC21/use.c

30 lines
415 B
C
Raw Normal View History

2022-04-07 15:58:01 +00:00
#include <stdio.h>
#include <stdlib.h>
#define BUILD1 23
int main(void)
{
int MyValue = 0;
printf ("\nThis code is common to all ");
#ifdef BUILD1
printf ("\nWe had BUILD1 defined, will adjust value accordingly ");
MyValue = BUILD1;
#else
printf ("\nBUILD1 was not defined, leaving MyValue alone ");
#endif
printf ("\nThe value in MyValue is %d ",MyValue);
printf ("\n\n");
return 0;
}