Create an implication operator in C#
using System;
class Example {
public static void Main() {
bool p=false, q=false;
Console.WriteLine("p is " + p + ", q is " + q);
if(!p | q)
Console.WriteLine(p + " implies " + q + " is " + true);
}
}
Output p is False, q is False
False implies False is True
|
HTML code for linking to this page:
|