49,757 Topics

Member Avatar for
Member Avatar for mary.fatulalohr

I tried fixing these errors but to no avail. Can someone please explain to me what I need to do to fix them? #include <iostream> using namespace std; int main() int arr_3d[4][3] = {{1}, {1, 2}, {1, 2, 3}, {1, 2, 3, 4}}; int row, col; for (row = 0; …

Member Avatar for David W
0
159
Member Avatar for neyoibarra

i have a question is there line of code or any code that restricts the user from inputting any letter or number or any key to my choice, but in a way that when he presses any letter and i restricted the alphabet keys then nothing will happne, or if …

Member Avatar for David W
0
129
Member Avatar for neha.jebin.18

i can't fix my errors. please help me out... here's the ITEMTYPE part of my code: //itemtype.h::::: #ifndef ITEMTYPE_H_INCLUDED #define ITEMTYPE_H_INCLUDED class itemtype public: itemtype(); void print()const; void initialize(int number); private: int value; }; #endif //itemtype.cpp:::::: #include "itemtype.h" #include <iostream> using namespace std; itemtype::Itemtype() // this is the line where …

Member Avatar for David W
0
266
Member Avatar for SWEngineer

I'm using "Digital Mars" to compile the following program: [CODE] #include <iostream> using namespace std; int main() { cout <<"My name is Abder-Rahman"; return 0; } [/CODE] And, this is what I get: [CODE] C:\Users\Software Engineer\Desktop\C++\dm852c\dm\bin>dmc print1 Fatal error: unable to open input file 'iostream' --- errorlevel 1 [/CODE] Any …

Member Avatar for abelard.louvel
0
762
Member Avatar for anyumba kevin

plz community members, am a new student in programing and i would wish you people help me write a programme : that accepts marks in five subjects for a student and stores them in an array.The programme then computes the avarage and grades of the student using the scheme below. …

Member Avatar for Learner010
0
145
Member Avatar for radhakrishnan.akshai.3

how can we pass the value of an array without using index of an array i.e subscript([]).

Member Avatar for rubberman
0
128
Member Avatar for Dang_1

I just have installed VS Ultimate 2013. When I compiled a simple code, it had an error LNK1104: cannot open file 'kernel32.lib' I tried to follow instructions on internet but it didn't work. My code #include <iostream> using namespace std; void main() { int x; cin>>x; cout<<x; }

Member Avatar for Ancient Dragon
0
99
Member Avatar for ManPui

\cs2370week8\cs2370week8Assign\cardDeck.o" c:/program files/codeblocks/mingw/bin/../lib/gcc/mingw32/4.7.1/../../../libmingw32.a(main.o):main.c:(.text.startup+0xa7): undefined reference to `WinMain@16' collect2.exe: error: ld returned 1 exit status Process terminated with status 1 (0 minutes, 7 seconds) 1 errors, 0 warnings (0 minutes, 7 seconds)

Member Avatar for mike_2000_17
0
1K
Member Avatar for john.kane.100483

Ok I really need this to fix up. And I've been awake all night just to fix the error. Can you help me with this errors. #1 Binary2Decimal() when I input a binary number it won't give an answer and it will skip the "Decimal Equivalent is: " it will …

Member Avatar for john.kane.100483
0
147
Member Avatar for BboyTurok1990

I redid the code again but this time I get an error c2061 identifier 'cout'. Someone explain to me this. I am pretty new with C++ I highly appreciate it. #include <iostream> #include <cmath> using namespace std; const double pi = 3.14159265; int main () { string name; string homework; …

Member Avatar for JasonHippy
0
268
Member Avatar for Mo90games

I have designed a programme that allows you to enter a number wich is then displayed in various forms however I am stuck with the code to convert the entered number into text can someone help? Below is what I have so far #include <stdio.h> #include <stdlib.h> #include <iostream> using …

Member Avatar for Ancient Dragon
0
142
Member Avatar for sailorsoldier

Hi guys! I have to write a code that checks to see if the password entered meets certain criteria and if it does not the whole function is supposed to start over. The criteria are that it must be atleast 12 characters and must have one upercase letter, one lowercase …

Member Avatar for Ancient Dragon
0
179
Member Avatar for Sara Masri

Write a program that tests a string is accepted or rejected according to a certain Finite State Machine (FSM). The program must read the FSM before testing the input string.

Member Avatar for rubberman
0
309
Member Avatar for neyoibarra

**hey guys, well i just want to get alittle help on something, so this is my prob, i finally got the first .txt files to be made by spereating them depending on there id numbers, which in short through each new employee is another new .txt file created, but the …

Member Avatar for Ancient Dragon
0
103
Member Avatar for BboyTurok1990

I need help with this c1075 error. Everytime I build it I get this error any idea what I did wrong? I appreciate it #include <iostream> #include <cmath> using namespace std; const double pi = 3.14159265; int main () { string name; string homework; name = "Randy Calhoun, Giannis Combe, …

Member Avatar for vmanes
0
236
Member Avatar for john.kane.100483

OK so I'm almost done with my program. How to put this in function like putting each case like void Binary2Decimal() , void Octal2Decimal() & , void Hexa2Decimal() in "TURBO C++"? Call a function like I only want to display only the Binary to Decimal case. #include<iostream.h> #include<conio.h> #include<stdio.h> char …

Member Avatar for Schol-R-LEA
0
226
Member Avatar for evaldaskowka

Hello, is this for loop possible? Im trying to get each new value for for(a;a<sum;a++) sum variable. After countless tries i am stuck and don't think it's possible to change that... When sum = sum + laikai[i+1]; exists compiler CMD window is not responding and checking for solution... Help would …

Member Avatar for evaldaskowka
0
398
Member Avatar for john.kane.100483

Hi I need help to correct this program :( NOTE THIS IS "TURBO C++" #include<iostream.h> #include<conio.h> #include<stdio.h> char value; char t, u, v; char answer; void Binary2Decimal() { gotoxy(1,17);printf("[BINARY TO DECIMAL CONVERSION]"); char b2,f2=1,d2=0; gotoxy(1,19);printf("Enter a Binary number: "); scanf("%d", &b2); printf("\n\n"); while(b2>0) { if((b2%10)==1) { d2=d2+f2; } b2=b2/10; f2=f2*2; …

Member Avatar for David W
0
202
Member Avatar for shahirulnizam
Member Avatar for David W

In the last few days, I have noticed a very old thread ... resurrected ... about a non-standard C getline function. To all who may like a C readLine function ... a C function that reads in a dynamic C string of any length ... a function with a similar …

0
211
Member Avatar for Fadhli_1

can this thing below work????? {#include<iostream.h> #include<conio.h> #include<stdio.h> char value; char t, u, v; char answer; void Binary2Decimal() { switch(t){ case 'a': //ok cout<<endl<<"[BINARY TO DECIMAL CONVERSION]"<<endl; cout<<endl; long b2,f2=1,d2=0; cout<<"Enter a Binary number: "; cin>>b2; cout<<"\n\n"; while(b2>0) { if((b2%10)==1) { d2=d2+f2; } b2=b2/10; f2=f2*2; } cout<<"Decimal equivalent is: "<<d2<<endl; …

Member Avatar for brett.warren.1612
0
129
Member Avatar for neyoibarra

SO MY PROB HERE IS JUST PLAINLY THE BACKSAPCE FEATURE OF MY PROGRAM EVERYTHING WORKS FINE EXCEPT FOR THE FACT THAT THE PROGRQAM IS CONSIDERING THE BACKSPACE KEHY AS PART OF THE CHARACTERS. int verification2() { system("cls"); char userChar[100], choice = 'Y', input, passChar[100]; for (int i = 0; i …

Member Avatar for nullptr
0
168
Member Avatar for Rashmi_1

Hi, I need some help with sorting my string comparison. Bascially what I have to do is this: To have numbers sorted properly even when they aren't justified with leading 0's: 1 2 ... 9 10 Instead of: 1 10 2 ... 9 Also to have numbers sorted properly even …

Member Avatar for Rashmi_1
0
897
Member Avatar for kimanthi

Hello everyone Am actually a newbie and learning C++ on my own. Have been trying to generate a code that prompts a student to enter his/details and after finishing. it couts his/her information. And prompts another student data to be entered. i have already some simple code here but it’s …

Member Avatar for kimanthi
0
246
Member Avatar for ReneeJA

Write a program that accepts the name and ID number of 5 students and stores them in an array. After all the students have been entered, the application should display the title “Student Roster” and then list the names in the array. 2D Array. #include <cstdlib> #include <iostream> #include <string> …

Member Avatar for ReneeJA
0
237
Member Avatar for Wayne_2

I have a final project for C++ class that requires us to demonstrat each thing that we've learned, a list of 24 things that range from using binary numbers, to loops to passing arrays and polymorphism and recursion. What I would really like to try is to make a simple …

Member Avatar for mike_2000_17
0
210
Member Avatar for john.kane.100483

Ok so I manage to built the program I want but there are problems. #1 The conversion from octal to decimal is not correct. #2 The conversion from hexadecimal to decimal some answers are correct. #3 I don't know how to character array this program. So what I am asking …

Member Avatar for Schol-R-LEA
0
247
Member Avatar for Wesam_2

Hi, I need some help . Bascially what I have to do is this: what doing cin.get in the prpgram just do space or give value.

0
127
Member Avatar for glamiex

This is the program that I made // Chapter 5, Programming Challenge 8: Math Tutor #include <iostream> #include <iomanip> #include <cstdlib> #include <ctime> using namespace std; int main() { int num1, // The first random number num2, // The second random number choice, // The user's choice of problem studentAnswer, …

Member Avatar for Schol-R-LEA
0
787
Member Avatar for Andrei_2

Sample Run ( OUTPUT ) Enter a word: computer The well-ordered words of length 3 that can be formed from the letters in the word "computer" are: cem ceo cep cer cet ceu cmo cmp cmr cmt cmu cop cor cot cou cpr cpt cpu crt cru ctu emo emp …

Member Avatar for samson.dadson.3
-1
147

The End.