49,761 Topics
| |
Hi! i m doing a project for my MSc academic year i need an implementation code for single perceptron network, which will have six inputs and a single output which will give me acurate result. | |
a C++ newbie here.. I am doing the question at the end of Ch3 which is about classes, objects, and constructors. I'm stuck on a few that asks you to write a C++ statement for each: (On 5, I wasn't sure how to give a value in the same statement.. … | |
does anyone know how to make an array search for how many words are in it? | |
Hi everyone...I am building a program to input students names(first and last) and also GPA. I have everything working but the sort by last name. Everything works fine, even the GPA sort but the last name sort will not. Please help. Below is the function in my program i am … | |
Hi guys, can you please describe the knapsack algorithm in English. I googled this, the first page was wikipedia. The algorithm there is too mathematical which doesn't help me to understand the solution. Can you please describe its algorithm? | |
I've been trying for hours to find out how to display an inputed word backwards but I just can't figure it out. Could someone help me please!! Thank you guys for your time. | |
Why does my file operation code write random data over the first two numbers I store in the file. The code compiles and runs without error messages, but I try to store the vector [0 0 0 0 0] and instead I get [20520 2414 0 0 0]. I am … | |
how to i check whether the map1 exist or not for some string in map <string, map1<string, int> > map2 | |
Hello guys.. I'm working on a project. There are 3 classes. Two are inherited from one. This is the implementation of the main class. There's an error. I have no idea how to debug it. Would you please check it?! [CODE]# include <iostream> # include <string> # include "MainMenu.h" using … | |
I have been studying graphs currently and came across a way to implement it. [code] #include<iostream> #include<vector> #include<string> #include<map> #include<functional> #include<cstdlib> using namespace std; struct vertex; struct edge { vertex *dest; double cost; edge(vertex *a=NULL, double b=0) { dest=a; cost=b; } }; struct vertex { string name; vector<edge> adj; vertex(string … | |
Hi, I've been working alot on a program lately, and I'm actually veeery close to done. Atleast until I come up with something more to add. The most useful function of this program, is the ability to create Shortcuts, which at the same time creates a command to start it. … | |
chk this piece of code [CODE]#include<iostream.h> using namespace std; class hi { public: void print() { cout<<"hi"; } }obj; int main() { hi *h; h->print(); } [/CODE] output---> hi -------------------------------------------------------- [CODE]#include<iostream.h> using namespace std; class hi { public: void print() { cout<<"hi"; } }obj; int main() { obj.print(); } [/CODE] … | |
Today I've learned some concepts about Pointer in C++ and I have a confusion in this code snippet and its result. Source Code: [code] // Pointer array #include <iostream> using namespace std; void main () { char * say = "Hello"; // cout << "say = " << say << … | |
Hey everyone I'm a college student taking semester two of C++ and we have a project using classes. This semester we are strictly using Vi to edit and compile my code. WARNING THIS CODE IS NOT THE WAY I WOULD PERSONALY WRITE IT, BUT MY INSTRUCTOR INSISTS ON THIS FORMAT. … | |
Hello guys, by the way I am a newbie here. This is my first post in this forum. I am now doing a window application(MFC.exe-dialog based) using the Microsoft Visual C++ 6 Enterprise Edition. Actually I am doing the simple application that read a string from text file. I only … | |
i wrote this module code but not sure if this is how you write a module. Is there anything i have missed?? [CODE]int FirstModule(int section) { cout<< "Pick a number " <<endl; cout<<endl; cin>>number; if (number == 1) value = 1.00; else if (number == 2) value = 1.10; else … | |
Hi, so ive been teaching my self pointers, and I just wanted to clarify what I assume so far. You cant declare: int var1 = &var2; You MUST use a pointer to store an address: int *var1 = &var2; When assigning a pointer variable, it must always point to an … | |
So I am new to C++, but I have read on dynamic memory and pointers. I know java well, but java gives you a lot of helpers, C++ not so much D: Ok so I am using VS 2008, and I am just rather baffled on how to get started. … | |
Hi there, I am new to C++ and trying to get my head around it. I am writing really simple and small programs and I have Visual C++. Now, can anybody summarize how I can run a program I wrote with C++ on Visual? The guide that comes with the … | |
Hi. I have a working program that lets you put info about a coupon. and then later on you can search for coupons, display them or remove them from the linked list. My problem is that, we are not supposed to perform input operations from our classes. But the way … | |
Hello.. I'm working on my project.. It's not done yet.. But i wanna debug these errors now first.. Please would someone check them for me. Thanks.. Here is the interface: [CODE]# ifndef MAINMENU_H # define MAINMENU_H # include <iostream> using namespace std; class MainMenu { public: MainMenu(); MainMenu(string the_name); MainMenu(string … | |
i cave this code [CODE] #include <iostream> #include <cstdlib> #include <cassert> using namespace std; typedef int typos_akmis; template <class typos_stoixeiou> struct korifi { typos_stoixeiou dedomena; /* i would like to do korifi<typos_stoixeiou> * ->kdktis */ korifi<typos_stoixeiou> * epomenos; akmi<typos_stoixeiou>* kefali; /* here is the problem */ int episkeftike; } ; … | |
hello everyone, im just confused on how to create GUI using the visual c++, could you help me.. coz i tried one but it doesnt work at all, do i haVE to setup anything on its properties | |
ok, so I have the following code. [CODE]#include <iostream> using namespace std; int main() { char name[80]; cout << "\n\nEnter your name: "; cin >> name; cout << name; return 0; }[/CODE] but here's the problem. whenever I enter a space in the name, everything after the space doesn't appear … | |
Hello everyone, I'm new to C / C++, and just wanted to make a file which can delete an item. The code worked, but when I want to give a path, it doesn't work anymore. Any help? [CODE] #include <iostream> #include <stdio.h> using namespace std; int main() { remove ("c:\users\asus\new.docx"); … | |
I know how to make 64 bit integers but how do I make 64 megabit integers? That is a bit rate of (1024^3)*64 bits. Is this a simple job as I don't know where to begin. I thought somebody might know of a library/script that will allow custom bit rates … | |
Hi, I'm just learning win32 and i wanna know: is it really necessary that i memorize all of the syntax. Is that what professionals do? Or can I just copy and paste it every time and just know what it does. Thanks, Hawkpath | |
I am relatively new to C++ and am currently taking a course for it. One of my assignments is to make a calculator for hourly wages and figure gross and net pay based on a fixed percentage for taxes. I am able to compile the code if I change the … | |
If I have a void pointer that needs to point to a struct. I'm not sure how to access the struct through the pointer. Can I even do that? If so, how? [CODE] #include <iostream> struct test { int var1; int var2; }; int main() { void *pPointer; pPointer = … | |
Hello all I am a second year C++ student in college and I am running into some issues with a code assignment I am writing. *Note: I realize that there may be better ways of doing the code but I am following my instructors guidelines so please no posts about … |
The End.