Advertisement
adventuretimeh

algebra booleana in c

Dec 22nd, 2019
194
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
C 0.67 KB | None | 0 0
  1. #include <stdio.h>
  2. #include <stdlib.h>
  3. #include <stdbool.h>
  4. #define PrintBool ("x")  ("x? VERO":"FALSO")
  5. /* run this program using the console pauser or add your own getch, system("pause") or input loop */
  6. //SE QUALCUNO MI AIUTA//
  7. int main(int argc, char *argv[]) {
  8. bool a,b,x;
  9. printf("dammi a");
  10. scanf("%s",&a);
  11. printf("dammi b");
  12. scanf("%s",&b);
  13. printf("%s and %s => %s\r\n",PrintBool (a),PrintBool (b),PrintBool (a&&b));
  14.     return 0;
  15. }
  16.  
  17.  
  18. 4   36  C:\Users\A\Desktop\main.c   [Error] expected ')' before ':' token
  19. 13  30  C:\Users\A\Desktop\main.c   [Note] in expansion of macro 'PrintBool'
  20. 4   19  C:\Users\A\Desktop\main.c   [Error] called object is not a function or function pointer
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement