Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- #include <stdio.h>
- int main() {
- FILE *pFile;
- pFile = fopen("okt_out.txt", "w");
- fprintf(pFile, "a\tb\tc\td\te\tres\n");
- for(int a = 0; a < 2; a++)
- for(int b = 0; b < 2; b++)
- for(int c = 0; c < 2; c++)
- for(int d = 0; d < 2; d++)
- for(int e = 0; e < 2; e++)
- fprintf(pFile, "%d\t%d\t%d\t%d\t%d\t %d\n", a, b, c, d, e, ((a||b||c||d||e)&&(a||b||c||!e||d)&&(a||b||c||!d||!e)&&(a||b||!c||d||e)&&(a||b||!c||d||!e)&&(a||!b||c||d||e)&&(a||!b||c||!d||!e)&&(a||!b||!c||d||e)&&(a||!b||!c||d||!e)&&(a||!b||!c||!d||e)&&(!a||b||c||d||e)&&(!a||b||c||!d||!e)&&(!a||b||!c||d||!e)&&(!a||!b||c||d||e)&&(!a||!b||!c||d||!e)&&(!a||!b||!c||!d||e))); //formula
- fclose(pFile);
- return 0;
- }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement