This assessment was given t linguistic department please check and confirm if you are to do this assignment.

## CSC 101 Assessment QUESTION

## CSC 101 ASSESSMENT SOLUTION

**1) Given that X2=3DFF base 16, we can convert it to base 10 by multiplying each digit by the corresponding power of 16 and adding the results.**

The digits in 3DFF are 3, D, F, and 1. Their place values in base 16 are 16^2, 16^1, 16^0, and 16^0, respectively.

**Answer**

X2 = (3 x 16^2) + (D x 16^1) + (F x 16^0) + (1 x 16^0)

= 576 + 216 + 15 + 1

= 808

**2) given that nkechi just got married draw a flow chart that can display nnanna if a first born is male and kamsiyo if the second born is a female**

ANSWER

Start

Is the firstborn male?

Yes → Print “Nnanna”

No → Go to step “Is the secondborn female?”

Is the secondborn female?

Yes → Print “Kamsiyo”

No → Print “No child yet”

End

**3) Given two teams A and B draw a flow chart that will A as a winner if only ronaldo plays and play the position 7 else b is the inner if merci plays and plays 9**

**ANSWER**

Start

Is Ronaldo playing?

Yes → Is Ronaldo playing in position 7?

Yes → Team A wins

No → Go to step “Is Messi playing?”

Is Messi playing?

Yes → Is Messi playing in position 9?

Yes → Team B wins

No → Team A wins

End

## NO 4

**4) Given that the las two digits of your reg no is a number of binary and u = AS draw a true table of i) A & B given that B is equal to 00101001. ii) Find a or b. iii) find a or b and A**

ANS

Given that the last two digits of your registration number is 04, which is equal to 00000100 in binary, we can construct the truth table for A & B as follows:

i)

A | B | A & B |
---|---|---|

0 | 0 | 0 |

0 | 1 | 0 |

1 | 0 | 0 |

1 | 1 | 1 |

As you can see, the output of A & B is 1 only when both A and B are 1. Otherwise, the output is 0. |

ii)

The truth table for A or B is as follows:

A | B | A or B |
---|---|---|

0 | 0 | 0 |

0 | 1 | 1 |

1 | 0 | 1 |

1 | 1 | 1 |

As you can see, the output of A or B is 1 when at least one of A and B is 1. Otherwise, the output is 0. |

iii)

The truth table for A or B and A is as follows:

A | B | A or B and A |
---|---|---|

0 | 0 | 0 |

0 | 1 | 1 |

1 | 0 | 1 |

1 | 1 | 1 |

As you can see, the output of A or B and A is always 1. This is because A or B is always 1 when at least one of A and B is 1, and A is always 1. |

## 1 comment

Can you be more specific about the content of your article? After reading it, I still have some doubts. Hope you can help me.