Solved

sta*tic mem*ory que*ue

Posted on 2008-09-30
1
191 Views
Last Modified: 2012-05-05
I want resourcess about static memory queue implement in c.Is it possible the size of this queue to be parameter from the user??
0
Comment
Question by:Tom211
1 Comment
 
LVL 53

Accepted Solution

by:
Infinity08 earned 50 total points
Comment Utility
>> Is it possible the size of this queue to be parameter from the user??

Sure, if you make the queue dynamic :) You can use malloc/calloc to allocate enough memory for the queue, realloc to resize the queue, and free to release the memory for the queue.

        http://www.cplusplus.com/reference/clibrary/cstdlib/malloc.html
        http://www.cplusplus.com/reference/clibrary/cstdlib/calloc.html
        http://www.cplusplus.com/reference/clibrary/cstdlib/realloc.html
        http://www.cplusplus.com/reference/clibrary/cstdlib/free.html
0

Featured Post

How to run any project with ease

Manage projects of all sizes how you want. Great for personal to-do lists, project milestones, team priorities and launch plans.
- Combine task lists, docs, spreadsheets, and chat in one
- View and edit from mobile/offline
- Cut down on emails

Join & Write a Comment

Preface I don't like visual development tools that are supposed to write a program for me. Even if it is Xcode and I can use Interface Builder. Yes, it is a perfect tool and has helped me a lot, mainly, in the beginning, when my programs were small…
Windows programmers of the C/C++ variety, how many of you realise that since Window 9x Microsoft has been lying to you about what constitutes Unicode (http://en.wikipedia.org/wiki/Unicode)? They will have you believe that Unicode requires you to use…
The goal of this video is to provide viewers with basic examples to understand recursion in the C programming language.
The goal of this video is to provide viewers with basic examples to understand opening and reading files in the C programming language.

762 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question

Need Help in Real-Time?

Connect with top rated Experts

12 Experts available now in Live!

Get 1:1 Help Now