19,876 Topics

Member Avatar for
Member Avatar for Ankush dhingra

void main() { int a[10][10],b[10][10],c[10][10],i,j,k,m,n,p,q; printf("Enter The Rows And Cloumns And Of The First Matrix:"); scanf("%d %d",&m,&n); printf("\nEnter The Rows And Cloumns And Of The Second Matrix:"); scanf("%d %d",&p,&q); printf("\nEnter Elements Of The First Matrix:\n"); for(i=0;i< m;i++) { for(j=0;j< n;j++) { scanf("%d",&a[i][j]); } } printf("\nEnter Elements Of The Second Matrix:\n"); …

-5
78
Member Avatar for imolorhe

Hello. Please, i have this little question of finding the product of two matrices in which the user enters the number of rows and columns. i would appreciate it if a solution is given and even more if there are more than one solutions to the question. thanks.

Member Avatar for Calipe
-5
205
Member Avatar for nedsnurb

Hi Guys, I am writing a program which enables the user to enter a size for a square and then they can choose to output it in several ways, clear filled horizontal/verticals lines. The first two I have manged however the latter horizontal/vertical I cant quite get right, as they …

Member Avatar for VernonDozier
0
79
Member Avatar for Iam3R

Hi, i like to know what are the different systems that have gstreamer built in, or systems which allows gstreamer to be installed. I also like to know what this below lines specifies: I found this in my shell of proc/version file Linux Version 2.6.9-5.Elsm gcc version 3.4.3 20041212 (red …

Member Avatar for gerard4143
0
109
Member Avatar for Justea

hi, Im coding a sodoku program base on backtracking, but somehow it did not work as what I expected, can help me figure out what's the problem? [CODE]sodoku.c #include <stdio.h> #include <stdlib.h> #define true 1 #define false 0 void printGrid(int board[]) { int i,j; if (board==NULL){ printf("No Solution\n"); return; } …

Member Avatar for dkalita
0
74
Member Avatar for matrix0978

hey guys, i programmed a bubble sort function in C and it doesnt seem to be sorting properly. Ive searched the forums and have seen similar posts and tried them but they dont work. :( Hoping someone could look over it to see if the concept/sytax is right. [CODE] typedef …

Member Avatar for matrix0978
0
243
Member Avatar for yasaswyg

So I have part of my code done and I'm stuck on how to sort structures. This is the code i have until now. Its supposed to ask the user 3 things title, artist name, rating of song and im supposed to ask the user to sort them in certain …

Member Avatar for dkalita
0
203
Member Avatar for gerard4143

I wrote this very small program that works fine until I remove the comments for the fprintf function. Basically the program will prompt the user for a numeric value, when the user guesses right(1234) the program exits. When I remove the comments the program never exits...Does anyone have any idea …

Member Avatar for gerard4143
0
133
Member Avatar for cabosun

So I am suppose to write a program that will implementing one method if computing checksums for a file containing integers. I am executing the program by a command line from the following form: p4a inputfile outputfile I can compile the program in Dev C++ compiler with no errors. But …

Member Avatar for gerard4143
0
81
Member Avatar for thure

I'm having trouble with a forking program. One process writes to a file, the other waits for the file to be written, prints something out, then deletes it. They essentially process in order based on whether the file is there or not. The processes should be outputting more useful information …

Member Avatar for thure
0
115
Member Avatar for bufospro

Hi, I am trying to make a server-client program about a bank. When a client connects to server , he has to send a character so as to define the operation like 'D' for create account. And I would like when client sends q to terminate . The character is …

Member Avatar for bufospro
0
116
Member Avatar for tasosa

Hi all; I am so new in C.I have problem about array .I want to remove same element in array but i dont know how can i do. Can anyone help me example : 1,2,3,5,67,31,13,5,2,1,1,4, the program should produce -->>1,2,3,5,67,13,31

Member Avatar for tashfeen
0
239
Member Avatar for thure

Hi there, This is my first time working with an unsafe language, so naturally my first code would be full of memory-related bugs. I still have no idea how I ought to approach some of the problems I've been getting, and I've been resisting asking for help as much as …

Member Avatar for Aia
0
166
Member Avatar for shakunni

As part of my program, I have defined and initialized a structure. But when I compile it, gcc gives me the following error on all the initialization " initializer element is not constant". Anyone know why this is the case? [code] struct RECORD { char* username; char* password; char* type; …

Member Avatar for shakunni
0
130
Member Avatar for Bandin03

Hey everyone, I have a job interview coming up and despite the fact that most of the job is in C++, they want me to do the interview test in C which I have no experience in, not to mention my C++ is kinda rusty. Now I would normally have …

Member Avatar for Bandin03
0
128
Member Avatar for imolorhe

Hello. Please, i have this little question of finding the product of two matrices in which the user enters the number of rows and columns. i would appreciate it if a solution is given and even more if there are more than one solutions to the question. thanks.

Member Avatar for FIG-GHD742
0
112
Member Avatar for FIG-GHD742

Hello. I have a question about Const Int and Points I have this code [code] const int j=18; int *k= (int)&j; *k=110; printf("Data: %d -> %d; %d : %d-> %d\n", &j, j, k, &k, *k); [/code] this well return for me [b]Data: 2280676 -> 18; 2280676 : 2280672-> 110[/b] but …

Member Avatar for Aia
0
131
Member Avatar for A Tripolation

So I finally get to the end of this evil program, and then it won't compile because it says "type double not expected". Here is my error message in its entirety: program 3 item.cpp(111) : error C2062: type 'double' unexpected program 3 item.cpp(121) : error C2062: type 'double' unexpected program …

Member Avatar for banders7
0
242
Member Avatar for leena_gc

please can someone tell me the source code of a c program? the program is "create a c program to print the employee pay revision list using arrays and functions and structure" please do reply fast as i need help urgently

Member Avatar for sheikaman
0
165
Member Avatar for newcpp

I have a problem when handling the txt file in C++. My code is like this, and the test.txt file is in the attachment. there are two functions: [LIST=1] [*]int txtnum(ifstream& input, char* filename ) is to count the amount of numbers list in the txt file. [*]long filesize( ifstream& …

Member Avatar for Ancient Dragon
0
139
Member Avatar for Iam3R

can somebody explain the behaviour of the statement printf("%d"); is it any where depends on the statements that present before or after it. i have some satatements that allocates memory dynamically. its printing one of that value. is there any proper reason for undefined behaviour.

Member Avatar for Tom Gunn
0
114
Member Avatar for Iam3R

[CODE] #include <gst/gst.h> #include <stdbool.h> static GMainLoop *loop; static gbooleanbus_call (GstBus *bus,GstMessage *msg, gpointer user_data) { switch (GST_MESSAGE_TYPE (msg)) { case GST_MESSAGE_EOS: { g_message ("End-of-stream"); g_main_loop_quit (loop); break; } case GST_MESSAGE_ERROR: { gchar *debug; GError *err; gst_message_parse_error (msg, &err, &debug); g_free (debug); g_error ("%s", err->message); g_error_free (err); g_main_loop_quit (loop); break; …

Member Avatar for Iam3R
0
92
Member Avatar for NinjaLink

I recently have a thread open, but I feel it is starting to get too long, and the topic is kind of old since I have a new problem now. What I am trying to accomplish here is determining whether a word is a palindrome using queues. My program compiles …

Member Avatar for NinjaLink
0
199
Member Avatar for dylank

Hi, I am creating a crackme (or possibly keygenme, if i feel like it) that realys on a IsDebuggerPresent call to see if the user has olly or another debugger open analyzing it. My current code reads as follows: [CODE]#include <windows.h> #include <stdio.h> #include <iostream> #include <ctime> using namespace std; …

0
110
Member Avatar for ssDimensionss

hi im trying to write some code for a priority queue using an unsorted array..it should be easy but i have a few concerns about it.. say if i have a graph of something like this: node 0, priority 100 node 1, priority 50 node 2, priority 200 node 3, …

Member Avatar for ssDimensionss
0
193
Member Avatar for alvalany

hi friends, I wanted to do something like creating an executable file like a installation file . I don't want to do anything hardcore :) Just I have to copy the html file into a user defined directory in the computer and set the home page of the default browser …

Member Avatar for alvalany
0
58
Member Avatar for ninja_girl

Hello, I'm a C newbie (first time using C at university) and after reading a few books, I still have problem implementing & understanding structures and pointers. I have the following structure: [CODE]typedef struct data { double average; }Tdata; Tdata stat = {0};[/CODE] Now I have two functions which are …

Member Avatar for Ancient Dragon
0
91
Member Avatar for shmeeps

I'm working on a project for school. Normally I'm a C++ guy, but I have to go through standard C before that, so I'm struggling with certain aspects being different, such as getline. Here's essentially what I'm doing, I have a data file that has a certain about of lines …

Member Avatar for shmeeps
0
173
Member Avatar for orangejediman

Hello,all! I am attempting to make a program in which tetris music is played. However, to get the full effect, I need more than one beep at a time. I cannot use the getsound thing either, i am not allowed. It has to be using 'Beep()'. Is this possible, and, …

Member Avatar for mrnutty
0
101
Member Avatar for splurchner

This is a program I wrote for class, and its completely done and compiles with no errors, but I keep getting a segmentation fault and even after using GDB and putting print lines (with fflush attached) I cannot figure out what the problem is. I do however think I found …

Member Avatar for Dave Sinkula
0
189
Member Avatar for Ineedhelpplz

suppose I have: [CODE]#define special_for(X,Y) { register int i = 0; for (;i<X;i++) {Y} }[/CODE] It is used in the following functions: [CODE]init_lineholder(int nlines) { [COLOR="Red"]special_for(nlines, lineptr[i] = (char *)malloc(MAXLEN); tmp++;)[/COLOR] }[/CODE] AND print_lines() { [COLOR="red"]special_for(tmp, if (lineptr[(first+tmp-i)%tmp] == NULL) break;[/COLOR] else printf("%s\n", lineptr[(first+tmp-i)%tmp]) ; ) /* had to space …

Member Avatar for jonsca
0
91
Member Avatar for mo_91

Drawing Hello 1. Horizontal Hello 2. Diagonal Hello Enter choice: 1 * * ****** * * **** * * * * * * * ******* **** * * * * * * * * * * * * * ****** ****** ****** **** Drawing Hello 1. Horizontal Hello 2. Diagonal …

0
50
Member Avatar for kiel19
Member Avatar for domjdragon2
-2
135
Member Avatar for AdRock

I don't know if this is the right board for this but here goes I have finsihed writing my program and it compiles fine on windows using the MinGW compiler. Ihave it compiling and running fine I tried compiling on a linux machine to create an executable but i an …

Member Avatar for AdRock
0
177
Member Avatar for Ineedhelpplz

So I have an assignment that I have been attempting for 2 weeks now and the class has been given extensions twice now. Everyone seems to be struggling with this part of the assignment. The assignment is to do K&R Exercise 5-13, unix tail command. [COLOR="Red"] Instructions: "The program takes …

Member Avatar for Ineedhelpplz
0
247
Member Avatar for seo2005

Hi, This has been discussed ealier, but i would like to know how the loop executes 1. #include<stdio.h> 2. #include<conio.h> 3. void main() 4. { 5. int x,y,z; 6. scanf("%d",&x); 7. if(x>0) 8. { 9. y=x/10; 10 z=x%10; 11. x=y; 12. printf("%d",z); 13. } 14. printf("%d",x); 15. } Suppose I …

Member Avatar for pramodsajwan07
0
116
Member Avatar for shakunni

I need to edit every character of a string for an assignment; apply a simple Caesar cipher on it. What is the C equivalent of "charAt()"? I remember my prof saying that all strings are terminated with a certain character in C and that you could run a while loop …

Member Avatar for shakunni
0
85
Member Avatar for debasishgang7

hi i want 2 know ho to make Instant Messenger client with c++. pls. provide web resources if available.., .. pls..

Member Avatar for kabeer.khan
0
2K
Member Avatar for Natsu29

Hello all! Looking for some help with this, I've been using a book to make an sql database to store names, and was hoping to use a button to randomly select any of the names in the database to be allocated to one of two machines. Also there is a …

Member Avatar for Natsu29
0
136
Member Avatar for liemonline

Hi, I'm a beginner to C++. I'm writing a linked list template but I get this error: 1>Tester.obj : error LNK2019: unresolved external symbol "public: __thiscall List<int>::~List<int>(void)" (??1?$List@H@@QAE@XZ) referenced in function _main 1>Tester.obj : error LNK2019: unresolved external symbol "public: __thiscall List<int>::List<int>(void)" (??0?$List@H@@QAE@XZ) referenced in function _main I'm using Visual …

Member Avatar for jonsca
0
1K
Member Avatar for ankur_

I am starting to learn C basic OS Concepts and I have to code them using C. Can anyone suggest me some good links where I can get basics of the complete OS Concepts like (process,IPC,thread,sheduling,File management,Memory management, Security) I have got good idea about the concepts but I am …

Member Avatar for ankur_
0
137
Member Avatar for ArjunRaja

Hi I am new to C. I want use properties file in C like how we use in "java" and "Perl". I want to read the values from a file and have to use those values in another file. This logic is to avoid hardcoding username and password.

Member Avatar for ArjunRaja
0
120
Member Avatar for Whilliam

Hello, I've been having problems with my program. I really don't get files that much. This is my code: [code=c] #include<stdio.h> #include<string.h> #include<stdlib.h> #include<conio.h> #define max 3 typedef struct { char FName[24]; char LName[16]; char MI; }name; typedef struct { unsigned long ID; name n; char course[8]; int level; }profile; …

Member Avatar for super-sonic
0
140
Member Avatar for LennieKuah

Hi there, Please help me. I am having problem trying to include Checkbox in 1st Column in DataGrid for all the Rows. Being a newbie and I am struggling doing it. I need your help.

Member Avatar for LennieKuah
0
196
Member Avatar for MeBjess

This is part of some class work I have to do, but this is not what I am turning in as my assignment! It does have some bugs, but as long as the user only enters an integer it runs fine. I have included just the part of the code …

Member Avatar for MeBjess
0
116
Member Avatar for briantrumpet

How do you stop forms from being movable and resizeable after you have maximized them in code.(this only happens if the maximize box is disabled) If you maximize a form with the maximize button it does not let you move or resize the form.

Member Avatar for DdoubleD
0
1K
Member Avatar for NinjaLink

Hi all, I am trying to reverse the numbers in an array using recursion, however, I am receiving an error that I can't figure out. If possible, I need some assistance on it. [B]Error:[/B] line 27 incompatible types in assignment of `int' to `int[5]' [I]intArray = reverseArray(intArray,low,high);[/I] line 57 invalid …

Member Avatar for basitkhan
-1
2K
Member Avatar for shakunni

How do you add a character to an existing string? In java you could just do: char c='a'; String b="posit"; b+=c; but I tried doing that in C and it doesnt work. Is there a workaround? Thanks.

Member Avatar for shakunni
0
93
Member Avatar for shakunni

I need to read data from a flat file [find below] into a linked list. Each line is a record and each record needs to be read into a different node. After I open the file using fopen(), I have the following problem: 1) How do I move from the …

Member Avatar for gerard4143
0
105
Member Avatar for adino2

Hi , just would like to ask on a few questions Is it possible to make a voice to text system without using the Speech SDK ??? If yes, can anyone provide me with the info on that? What can be used?

Member Avatar for Diamonddrake
0
82

The End.