15,555 Topics

Member Avatar for
Member Avatar for junrey laao

hi: i need to make a code for the process scheduling like round robin,first come first serve, preemptive and short job first. it should display all average waiting time for each scheduling.. and suggest what type of scheduling should be used... please help me... i need some help here...

Member Avatar for griswolf
0
85
Member Avatar for fg_aa_c

Does anyone know of any examples or tutorials for how to create a pthreads server? I have built a web server using fork() which works fine. I want to convert it to multi threading but I really cannot understand how the variables work in respect to mutexing, i don't understand …

Member Avatar for Ancient Dragon
0
106
Member Avatar for Splam Bub

Hello DaniWeb! I'm trying to return an array of strings from a function but I'm not sure how to do so. I've done the prerequisite Googling and have found people on this discussion board recommending to return char** which, it is said, can then be converted back into 2d array …

Member Avatar for Splam Bub
0
154
Member Avatar for vineeshvs
Member Avatar for vineeshvs
0
307
Member Avatar for bergqvistjl

Hi, what would be a easy way of taking chars from the BEGINNING of a string, and placing them in another variable, ensuring that they are removed from the original string, ideally at the same time? basically, say i have 2 strings, string1 and string2. string1 contains "helloworld" string2 is …

Member Avatar for WaltP
0
139
Member Avatar for nadleeh

if i have a list kinda like this "name" bobby "endname" "age" 34 "endage" "name" susie "endname" "age" 53 "endage" how would i sort through it ignoring the stuff in "" and copying just the names and ages into arrays. ive been using strtok and if statements but that doesnt …

Member Avatar for Adak
0
135
Member Avatar for thecstudent

Hello World! I am new to C and would like to write a C program to accomplish the following: I have an external 600GB USB disk device, Padlock Pro. The device, which can be seeing at: [url]http://www.amazon.com/Apricorn-Encrypted-Portable-External-A25-PLe256-640/dp/B003EYVJTU/ref=sr_1_1?ie=UTF8&qid=1298479333&sr=8-1[/url] has a number pad on it. It uses a maximum key of 16-digit, …

Member Avatar for thecstudent
0
201
Member Avatar for chound

Is it possible to create programmes to run on coumputers thad do not have any operating systems? :evil: :cheesy: :sad:

Member Avatar for aer9998
2
219
Member Avatar for Protoroll

So I converting a decimal value into hex, but I need to print it out from an array. I'm not sure where to go from here. [CODE] #include <stdio.h> #include <stdlib.h> #include <string.h> int hexa = 16, deci, quotient, p; void dec2hex(unsigned int x, char hex[]) { for (p = …

Member Avatar for Ancient Dragon
0
121
Member Avatar for sonuja

how to connected data base(sql) with c language......? with exampal...?

Member Avatar for Ancient Dragon
0
128
Member Avatar for salvador01

hi! good day im a newbie and trying to learn functions in C. and im having a problem with functions. int charges (int l, int w) { int c_charg; c_charg = 8.23 * area; } l = 6, w= 3, and area = 18 problem is 'c_charg' is assigned a …

Member Avatar for jonsca
0
87
Member Avatar for vineeshvs

i allocate memory for b_edge in function bark_edge and give value to only b_edge[1][1] and try to return b_edge from function. segmentation fault comes? can you please check why? [CODE]//function bark_edge+main program #include<stdio.h> #include<math.h> #include<stdlib.h> double **bark_edge(); main() { double **b_edge; b_edge=bark_edge(); printf("%f",b_edge[1][1]); } //FUNCTION-bark_edge double **bark_edge() { int i=0; …

Member Avatar for vineeshvs
0
179
Member Avatar for vineeshvs

segmentation fault comes in the program? please help? is there any way i can check in which part of the program is the mistake? Thanks daniweb and members... [ICODE] //function bark_edge+main program #include<stdio.h> #include<math.h> #include<stdlib.h> double **bark_edge(int f_size,int samp_freq); double **transpose(double **x,int M,int N); main() { int f_size=1024; float samp_freq=44100,fcmax=samp_freq/2; …

Member Avatar for vineeshvs
0
393
Member Avatar for Nurkan

[B]Hello To All Programmer:),,,im a beginner plzz help to make this program.. Make a program of am institution using manual system flow and convert it to computerized system using Turbo C program..:S the institution is Boutuque.. plzz help me...TY programmer,,[/B]

Member Avatar for Adak
-1
103
Member Avatar for axn

How do I read and print just n(10) lines in a file and not whole file. [CODE]#include<stdio.h> #include<string.h> int main() { char line[50]; FILE *datafile; datafile = fopen("/data3", "r"); while(fgets(line,sizeof line,datafile)!=NULL) printf(" %s\n", line); fclose(datafile); return 0; }[/CODE]

Member Avatar for Narue
0
162
Member Avatar for sonuja
Member Avatar for Adak
0
79
Member Avatar for sambho

Hi guys I have some problem regarding getting prime factors and distinct prime factors. I manged to get the prime factors but I got stuck on how to get the distinct prime factors.........I don't know how to select unique prime factors and print them....Help me out guys........ Thank you in …

Member Avatar for rajanpathak
1
918
Member Avatar for Dec28

Not sure why my comparisons aren't working between my input (text) and my several char arrays. I'm trying to get the user's input to terminate certain functions as you'll see below. I realise it's not the most efficient code but if there's anything obvious I'm missing please let me know. …

Member Avatar for Narue
0
210
Member Avatar for gyuunyuu

[CODE]#include <stdio.h> #include <stdlib.h> #include <string.h> typedef struct { int count; // counter to use the word's occurrence char word[99]; } word; char str[99]; word myword[50]; int main() { FILE *myfile; if ((myfile = fopen("wordlist", "r")) == NULL) { printf("\n Error:Can't open file \n "); exit(0); } int position = …

Member Avatar for Adak
0
131
Member Avatar for Utsav Chokshi

Question:Write a program which prints " Testing C Skills" without no use of semicolon. I have found one answer : [CODE]1. #include <stdio.h> 2. void main() 3.{ 4. if(printf("Testing C Skills")) 5. {} 6.}[/CODE]

Member Avatar for rajeevpareek
0
90
Member Avatar for gyuunyuu

[CODE]#include <stdio.h> #include <string.h> typedef struct { int count; // counter to use the word's occurrence char *word; } word; int main() { word myword[50]; FILE *myfile; if ((myfile = fopen("wordlist", "r")) == NULL) { printf("\n Error:Can't open file \n "); exit(0); } char str[99]; int position = 0; while …

Member Avatar for kings_mitra
0
109
Member Avatar for Prisms

Hello I have been working on this program for a few days and have gotten stuck. I allow the user to enter in a string and remove special characters and turn upper case characters to lower case. after all that is done i compare the characters in the string to …

Member Avatar for Prisms
0
309
Member Avatar for MatGreenfield

Hi, I am writing a piece of code that takes copies the contents of one file to another (which is created by the code, the name is given by user as an arguement). I've managed to successfully open and read in the source file, and the program will create the …

Member Avatar for MatGreenfield
0
100
Member Avatar for shinsengumi

Hello all. I've previously created a working socket program in C in a 32-bit machine and now I have to transfer it to a 64-bit machine. May I ask if there is anything I have to change in my program to make it work in a 64-bit machine? I did …

Member Avatar for Ancient Dragon
0
604
Member Avatar for virendra_sharma

i have sample for to find out prime number , but i want to optimise is more. can anyone plz help me. int i; for (i=2; i < num ;i++ ){ int n = num%i; if (n==0){ System.out.println("not Prime!"); break; } } if(i == num){ System.out.println("Prime number!"); } thnaks in …

Member Avatar for Adak
-1
134
Member Avatar for coding101

I need to read a text file and change each character into morse code, then send it to another file. is there an easier way than having 26 different arrays associated to a different letter?

Member Avatar for Adak
0
88
Member Avatar for dem10

Hey I am writing a double linked list dictionary of sorts. All of my functions were properly (add element after, move pointer, search, etc.). However, something is wrong with my add before function. Initially it adds elements fine, however if I decide to move the pointer to a new element …

Member Avatar for thekashyap
0
159
Member Avatar for gyuunyuu

I'm supposed to read all the words from text file and use bubble sort to sort the word and count their occurrence. As I read each word from file, what is the exact thing I need to do? Do I need to store the word (as char array) somewhere to …

Member Avatar for thekashyap
0
207
Member Avatar for paulkinzelman

I've spent several days looking for info about precisely how to do DLLs and have found bits and pieces here and there but noplace that ties it all together. I'm thinking this could grow into a 'how-to' for DLLs which might be useful for others as well. I'd like to …

Member Avatar for paulkinzelman
0
306
Member Avatar for zetologos

This program keeps adds the sum of numbers you put in. You can also quit by typing in quit, its not case sensitive since I have code which converts all uppercase letters into lowercase. This in fact is the problem. For some reason when I insert a number it works …

Member Avatar for zetologos
0
258

The End.