Use app×
Join Bloom Tuition
One on One Online Tuition
JEE MAIN 2025 Foundation Course
NEET 2025 Foundation Course
CLASS 12 FOUNDATION COURSE
CLASS 10 FOUNDATION COURSE
CLASS 9 FOUNDATION COURSE
CLASS 8 FOUNDATION COURSE
0 votes
73 views
in Computer by (55.2k points)
closed by

डीक्यू को समझाइए।

1 Answer

+1 vote
by (57.2k points)
selected by
 
Best answer

डीक्यू (Dequeue) ऑपरेशन- डाटा तत्त्व को क्यू से हटाने का काम दो भागों में किया जाता है। एक उस डाटा तत्त्व को एक्सेस करना जहाँ पॉइंटर पॉइंट कर रहा हो और दूसरा उसको वहाँ से हटाना।

निम्नलिखित स्टेप्स से डीक्यू ऑपरेशन परफॉर्म किया जाता है-

Step 1 – heck if the queue is empty.
Step 2 – If the queue is empty, produce underflow error and exit.
Step 3 – If the queue is not empty, access the data where front is pointing.
Step 4 – Increment front pointer to point to the next available data element.
Step 5 – Return success.

डीक्यू (Dequeue) ऑपरेशन के लिए एल्गोरिथ्यम

procedure dequeue
if queue is empty
return underflow
end if
data = queue[front]
front ← front+1
return true
end procedure
डीक्यू (Dequeue) ऑपरेशन का C भाषा में इम्पलीमेंटेशन
int dequeue ()
{
if(isempty())
return 0;
int data = queue[front];
front = front +1;
return data;
}

Welcome to Sarthaks eConnect: A unique platform where students can interact with teachers/experts/students to get solutions to their queries. Students (upto class 10+2) preparing for All Government Exams, CBSE Board Exam, ICSE Board Exam, State Board Exam, JEE (Mains+Advance) and NEET can ask questions from any subject and get quick answers by subject teachers/ experts/mentors/students.

Categories

...