Rules of Inference — AI Technical Interview Questions & Answers

Rules of Inference

Rules of Inference

  • Inference rules let you derive new sentences. Modus ponens: from P and P→Q infer Q. And-elimination, resolution, etc. Sound rules never invent falsehoods from true premises. Complete methods find every entailed sentence (in the fragment they cover).
  • Board: “If dirt then suck. Dirt is true.” Infer suck. That is modus ponens, not magic.
  • Output: idea / do / check for Rules of Inference. Fill those three in the viva.

Technical Interview Tip: Modus ponens with one AI action.

Code Examples for Rules of Inference

Example

# Rules of Inference
print("idea :", "Rules of Inference")
print("do   : one tiny example on paper")
print("check: one failure case")

Output: idea / do / check for Rules of Inference. Fill those three in the viva.

How to Explain Rules of Inference to an Interviewer

Explain Rules of Inference as if you are teaching a junior — definition, then one example.

Modus ponens: P, P→Q ⊢ Q. Sound vs complete.

What does the example print, and what does that prove?

idea / do / check for Rules of Inference

What mistake do freshers make with Rules of Inference?

Only the buzzword, no example