Logo  

CS256 - Fundamentals of Structured Programming

Displaying exercises/e5/files/h2.c

/**
 * Read three integers (say, a, b and c) using scanf.  Do not print a prompt.
 * The inputs will be either zero or one.  Produce the output "pass" or "fail"
 * depending on the values of a, b and c using the following
 * table:
 *
 *   a | b | c | output
 *  -------------------
 *   0 | 0 | 0 | "pass"
 *   0 | 0 | 1 | "fail"
 *   0 | 1 | 0 | "pass"
 *   0 | 1 | 1 | "fail"
 *   1 | 0 | 0 | "pass"
 *   1 | 0 | 1 | "fail"
 *   1 | 1 | 0 | "fail"
 *   1 | 1 | 1 | "pass"
 * 
 * Example input/output:
 * > ./h2
 * 0 1 0
 * pass
 */
#include <stdio.h>

int main(void)
{

  return 0;
}