Computer Science - 9210 OxfordAQA

Boolean Operations In A Programming Language

Gbogbo ọrọ náà

Read this out loud: staff may enter, and so may students who have paid. Now try to write it as one condition. Where do the brackets go? Does a member of staff who has not paid get in? English lets a rule stay comfortably vague until somebody has to enforce it; a program cannot. Three small words, NOT, AND and OR, are what turn a sentence like that into something a machine can decide.

This lesson covers the three Boolean operations the specification names, the truth tables that define them exactly, and the combinations of them that appear inside real conditions. You will learn the order the operations are carried out in, why a bracket can silently change who is allowed through a door, how to turn a condition inside out when you need its opposite, and the two compound conditions that beginners write which look right and are always true or always false.

Ebumnobi

  1. Be familiar with and be able to use:
  2. NOT
  3. AND
  4. OR.

Maapụ uche

E seela isiokwu a ka ị hụ otu echiche si ejikọta.

Mepee maapụ uche na ngwa

Akwụkwọ Ọmụmụ

A Boolean operation takes Boolean values and produces a Boolean value. That is a narrower job than an arithmetic operation, which is why there are only three of them and why each can be defined completely in a table of a few rows. The specification requires you to be familiar with and able to use NOT, AND and OR, and to use combinations of them within conditions for iterative and selection structures.

Ndetu Nkuzi Zuru Ezu di na Ngwa Green Bridge

Nweta ngwa Green Bridge CBT na ekwenti gi ma o bu kompiuta maka ulo akwukwo IGCSE zuru oke: akwukwo ule ndi gara aga, usoro nyocha, eserese uche, kaadi omumu na nkuzi olu.

Akwụkwọ ndụmọdụ zuru oke nwere eserese
Onye inyeaka mmụta AI
Ule nnwale nwere oge a na-ahazi ozugbo i mechara
Ọ dị na Android, Windows, macOS, na Linux Ngwa iOS na-abia n'oge na-adighi anya

Nnyocha Ọmụmụ

Ekele diri gi maka imecha ihe karịrị na Boolean Operations In A Programming Language. Ugbu a na ị na-enyochakwa isi echiche na echiche ndị dị mkpa, ọ bụ oge iji nwalee ihe ị ma. Ngwa a na-enye ụdị ajụjụ ọmụmụ dị iche iche emebere iji kwado nghọta gị wee nyere gị aka ịmata otú ị ghọtara ihe ndị a kụziri.

Ị ga-ahụ ngwakọta nke ụdị ajụjụ dị iche iche, gụnyere ajụjụ chọrọ ịhọrọ otu n’ime ọtụtụ azịza, ajụjụ chọrọ mkpirisi azịza, na ajụjụ ede ede. A na-arụpụta ajụjụ ọ bụla nke ọma iji nwalee akụkụ dị iche iche nke ihe ọmụma gị na nkà nke ịtụgharị uche.

Jiri akụkụ a nke nyocha ka ohere iji kụziere ihe ị matara banyere isiokwu ahụ ma chọpụta ebe ọ bụla ị nwere ike ịchọ ọmụmụ ihe ọzọ. Ekwela ka nsogbu ọ bụla ị na-eche ihu mee ka ị daa mba; kama, lee ha anya dị ka ohere maka ịzụlite onwe gị na imeziwanye.

  1. A holds True and B holds False. What is the value of A AND B? A. False B. True C. It depends on the language D. The expression is invalid Answer: A
  2. Which condition correctly tests that a number is between 10 and 20 inclusive? A. N > 10 AND N < 20 B. N ≥ 10 AND N ≤ 20 C. N ≥ 10 OR N ≤ 20 D. N > 10 OR N < 20 Answer: B
  3. In the expression A OR B AND C, which operation is carried out first? A. AND B. OR C. They are carried out left to right D. It is undefined Answer: A
  4. What is the exact opposite of the condition A AND B? A. NOT A AND NOT B B. NOT A OR NOT B C. A OR B D. NOT (A OR B) Answer: B
  5. A programmer writes IF Choice = "Y" AND Choice = "N" THEN. What happens? A. The block runs whenever Choice is Y B. The block runs whenever Choice is N C. The block never runs D. The block always runs Answer: C

Rue ajuju ndi a n'ime ngwa ahu

Rue ajuju ndi a n'ime ngwa ahu

Meecha Ajụjụ Ule Ọmarịcha

Ị chọrọ ime ajụjụ ule ọmarịcha gbasara Boolean Operations In A Programming Language? Budata ngwa Green Bridge CBT iji nweta ajụjụ ule ọmarịcha na nyocha zuru ezu gbasara isiokwu a.

Budata Ngwa Ahụ Na Google Playstore

Ihe nile ichoro iji nwee ihe ịga nke ọma na JAMB, WAEC & NECO.

Green Bridge CBT Mobile App
Onye Enyemaka Nkata AI Nke Ọmụmụ Ihe Ahaziri Maka Gị
Ajụjụ ule IGCSE, JAMB, WAEC na NECO karịrị 200,000
Ihe karịrị 1200 Nkọwa Nkuzi
Nkwado Na-enweghị Ịntanetị - Mụọ Ihe Mgbe Ọ Bụla, Ebe Ọ Bụla
Jadawalin Gada Kore
Akọkọ akọle iwe & Ibeere agbara
Sọfụma Ọrụ Gi & Ọganihu Gi
Nkọwa Miri Emi Maka Ọmụmụ Ihe Zuru Ezu