The Gateway to Computer Science Excellence
+2 votes
227 views

The minimum size of queue required when performing BFS on above graph is ________.
(Size of queue is represented by maximum number of element at any time).

I am getting 3.

Consider 3 dimensional Array A[90] [30] [40] stored in linear array in column major order. If the base address starts at 10, The location of A [20] [20] [30] is ________. (Assume the first element is stored at A[1][1][1] and each element take 1 memory location)

in Programming by Boss (18.2k points) | 227 views
+3

1) If starting element is E then 4, 

If any other starting element then 3.

2) In 3d array, to perform CMO,

first you have to traverse 19 positions of outer level, => 19*30*40 

then perform CMO as usual on inner 2d array, => 29*30 + 19

Hence total answer is => 10 + 19*30*40 + 29*30 + 19

0
It'll be 5 right?

C

BEDG

EDGAF
0

It is min size right?

ABF

ECF

ECG

ED

it will be 3

how 4?

0
If starting is E then all its 4 neighbours will be enqueued in the Queue
0
IF starting symbol is G then also 4 enqueud in the Queue

Please log in or register to answer this question.

Quick search syntax
tags tag:apple
author user:martin
title title:apple
content content:apple
exclude -tag:apple
force match +apple
views views:100
score score:10
answers answers:2
is accepted isaccepted:true
is closed isclosed:true
50,647 questions
56,492 answers
195,439 comments
100,696 users