Tag: technology

Questions Related to technology

  1. A. Chart of accounts

  2. B. Cross validation rules

  3. C. All of the above

  4. D. None of the above


Correct Option: B
  1. A. Budgets

  2. C. Creating journals

  3. C. Reversing Journals

  4. D. none of the above


Correct Option: A
  1. A. Financial Statement Generator

  2. B. Global Consolidation System

  3. C. All of the above

  4. D. None of the above


Correct Option: C
  1. A. record financial activity of a company and to produce financial and management reports

  2. B. Receive payments from the customer

  3. C. Pay the invoices to the suppliers

  4. D. None of the above


Correct Option: A
  1. A. Fixed Assets

  2. B. Projects

  3. C. Inventory

  4. D. All of the above


Correct Option: D

In which all cases does an exception gets generated. Select the two correct answers. int i = 0, j = 1;

  1. if((i == 0) || (j/i == 1))

  2. if((i == 0) | (j/i == 1))

  3. if((i != 0) && (j/i == 1))

  4. if((i != 0) & (j/i == 1))


Correct Option: B,D

AI Explanation

To answer this question, let's go through each option to understand why it is correct or incorrect:

Option A) if((i == 0) || (j/i == 1)) - This option is incorrect because it uses the logical OR operator (||) which short-circuits and does not evaluate the second part of the condition if the first part is true. Therefore, an exception will not be generated in this case.

Option B) if((i == 0) | (j/i == 1)) - This option is correct because it uses the bitwise OR operator (|) which evaluates both parts of the condition. If i is 0, the second part of the condition (j/i == 1) will be evaluated, and since dividing by 0 is undefined, an exception will be generated.

Option C) if((i != 0) && (j/i == 1)) - This option is incorrect because it uses the logical AND operator (&&) which short-circuits and does not evaluate the second part of the condition if the first part is false. Therefore, an exception will not be generated in this case.

Option D) if((i != 0) & (j/i == 1)) - This option is correct because it uses the bitwise AND operator (&) which evaluates both parts of the condition. If i is not 0, the second part of the condition (j/i == 1) will be evaluated, and since dividing by 0 is undefined, an exception will be generated.

The correct answers are B) if((i == 0) | (j/i == 1)) and D) if((i != 0) & (j/i == 1)). These options are correct because they use the bitwise OR and bitwise AND operators, respectively, which evaluate both parts of the condition and can result in an exception if dividing by 0.