49,761 Topics
| |
hey guys, I am supposed to write 3 boolean functions listed below. my problem is that I don't really understand the questions and don't know where to start. it would be really great if someone just do one of the functions to give me an example so i could finish … | |
write a c++ program that stores the following numbers in the array named miles:15,22,16,18,27,23, and 20. have your program copy the data stored in miles to another program named dist, and then display the values in the dist array. your program should use pointer rotation when copying and displaying array … | |
does anyone know how to make a variable type to store GUIDS? I can currently read GUIDS however storing them is proving difficult. Ideally I would like to do this to compare them and organise them based on a variable type. I am a beginner however am eager to jump … | |
I appreciate any help ........I treid many solution it did not work! [CODE]aTree.AddString(L"barak");[/CODE]//this is working 100% when I tried to do this : [CODE]char *p; p = new char[500]; //read the value of p from file one line at a time aTree.AddString(p);//not working [/CODE] | |
I wish to do a program in c++ that enables me to play music as part of my school project. I want to know if is this is possible. I also wish to know if photos and other media can be similarly accessed and where i can get information on … | |
print a list of integers from 1 to N that are both divisible by 2 and 3.and after producing the list, count the numbers of integers found. | |
can somebody teach me or show me a code that converts a binary to a decimal.... >_< and if you could kindly explain how it happens.... should be in TurboC programming.... | |
I need to write a C++ code that will ask the user to enter either 1 or 2. If 1 is entered the program must count all even numbers from 0 to 100. (I got that part done) If 2 is entered you are suppose to prompt the user to … | |
5 student picked up 5 balls. they do not choose same number but during print out process, the program is writing different ball number i dont know why? [CODE]#include <cstdlib> #include <iostream> #include <conio.h> using namespace std; int main(int argc, char *argv[]) { int i; int ogr[5] = {0}; // … | |
Hi, I have to pass a void pointer in a function and at the other end I have to read some values from this void pointer. I planned of creating a class and setting up required variables into an object and then I set this [CODE] void* ptr = obj … | |
I have an assignment where I'm taking a file from my computer and using the numbers to pull something out. I'm supposed to take numbers from a file and checking to see how many times the number is in the file. But i can't seem to figure it out. This … | |
This function should take as it's arguments two integer values. The function should return the smaller of the two values. From main ask the user for two integer values. Pass the two values to your smallest function, then print out the returned value. I am new to c++ and struggling … | |
Hi I was just wondering if I create a pointer using the new operator and then I call the new operator on that same pointer later on would that overwrite the existing pointer so that I do not waste memory on the heap or do I have to delete it … | |
I wrote this program about four hours ago and everything but my if loop is working. I wrote a separate one in a test file and it works, for the life of me I can't get it to work in this program. When inputting anything other than a y or … | |
Create a logical function IsConsonant(ch), which returns true if ch is a consonant. The characters considered vowels are: 'a', 'e', 'i', 'o', and 'u'. Your function can assume ch will be either an upper- or lower-case letter. I have no clue what i am supposed to do. Can i get … | |
ok guys I need your help. What i need to do is create a program that prints out a user specified pattern. the user specifies the size and which pattern. the patterns should llok like this Patter 1 Pattern 2 Pattern 3 Pattern 4 5$$$$ $$$$5 $$$$$ $$$$$ $5$$$ $$$5$ … | |
Q: find the area of the rectangle using 2 objects This is my code with out the 2 objects normal code [CODE] #include<iostream> using namespace std; class rectangle { int q,w ; public : void set_value (int e, int r) { q=e; w=r; } int area() { return q*w ; … | |
I just learned about heaps today. It looks like STL wants you to create a heap by first creating a vector, then using make_heap from <algorithm>: [code] std::vector<SimpleClass> Numbers(8); // ... populate ... // convert Numbers into a heap make_heap(Numbers.begin(), Numbers.end()) ; [/code] Why is there not a <heap> just … | |
Why am I getting this errors when running this program where i tried to create 2 specialized templates to use int and double: [code] #include <iostream> using namespace std; template<> int sum<int>(int* array, int start, int stop, int init = int()) { int* stp = (array + stop); int* str … | |
I have a question: Say I have a text file with a bunch of words on it, say the following: hello baby crap hate ground soul fart hot render Now, if I make a program that requires the user to input a word, how would I go about searching the … | |
Hello all, I am a long time browser and first time poster here. Right now I am a little stuck on my project and could use a little help. The program opens a .txt file and then reads the data and places the data accordingly. The issue this time compared … | |
Hello I have put a web browser control on the form. Now I use different URLs for this browser but sometimes popups and "Internet Explorer Script Error" windows popups appear. My question is how it would be possible to block popups for this instance below of webBrowser1 ? I am … | |
So I have a file I wanna put its content in an array and that needs malloc or new. I do that on a large project, it was working fine but i guess some changes were made to this project and now that malloc causes a crash and "char* array … | |
Hello everybody, really need some help getting this code to add up even and odd numbers from a set of integers. But it also needs to default or continue through if input is incorrect (i.e.- $,@,#,3.4) and so on. Here is what I have so far. Thank you. [CODE]#include <iostream> … | |
Hello, I wonder how it is possible to read a multilined textBox line by line into a List<String^>. I dont get the below code to compile so I might be missing something here ? [CODE]array<String^>^ mylines = textBox1->Text->Split(System::Environment::NewLine); List<String^>^ getLines = gcnew List<String^>(); String^ getLine = ""; for (int i … | |
Hi i am student of bs . I Join Late in uni I have some problem can u please help me out to make these programs | |
hello can you make and run a program that will display the numbers 1,2,3, and so on depending on the number of lines the user will enter. example output: enter a number=3 1 23 456 thanks for the help.. | |
Hello, Can anyone please suggest me how to acquire the data from a RS 232 port continuously..i.e The port will be open and it should keep reading data till I say stop. without using timer. And data is coming in every half second in rs 232 Thanks in advance for … | |
Hello, Is this function "EscapeCommFunction" is correct to set RTS signal? Here is my code. I want to set on RTS before sending data to rs232, and set off RTS after sending data. // RTS on. EscapeCommFunction(*hComDevice, SETRTS); // Sending data to port. fWriteStat = WriteFile(*hComDevice, txbuf,(DWORD) iTxPosition,&dwBytesWritten, NULL) ; … | |
[CODE]#include <iostream> using namespace std; int main () { int x; cin>>x>>"\t"; int A = A[x]; return 0; }[/CODE] the error is "subscript requires array or pointer type" how can i input my desired number of size by using cin for x??? help |
The End.