49,766 Topics

Member Avatar for
Member Avatar for sherry ibrahim

write a program select an operation 1)innerproduct 2)matrix*vector 3)vector*matrix 4)matrix*matrix 5)transpose 6)exit how i wrote this with switch and for loop

Member Avatar for deceptikon
0
56
Member Avatar for obinaysamanoden

Average #include <iostream> #include <cstdlib> using namespace std; bool check(double element[], int count); int main() Average #include <iostream> #include <cstdlib> using namespace std; bool check(double element[], int count); int main() { char redo; do { system ("cls"); double elements = 0, i = 0, j = 0, average_elements = 0; …

Member Avatar for David W
0
279
Member Avatar for Neon_1

Hi, I am very new to CMake. In fact, I am trying this tutorial http://www.cmake.org/cmake-tutorial/. I do not understand some of the words prescribe there but I can manage. The problem I have with tutorials is the inclusion of TutorialConfig.h. I check the tutorial files and such file doesn't exist. …

Member Avatar for mike_2000_17
0
1K
Member Avatar for LATCH808

can someone tell me whats wrong with it or what i should do? #include <iostream> #include <iostream> #include <string> #include <fstream> #include <vector> using namespace std; List storage[50]; int e = 50; int intro(void) { int userChoice; cout << "Enter 1 to checkout or 0 to end checkout."; cin >> …

Member Avatar for bernardo.mclobo
0
432
Member Avatar for Fenrir370

So im doing an assignment for class and im not sure what/how to proceed, im struggling with storing randomly generated numbers in an array and then calling on them later to display how many times the random number has been called them. as you might notice i already have my …

Member Avatar for Fenrir370
0
253
Member Avatar for bythescruff

Hi folks. I'm about to evaluate an implementation of SYCL for ease of use and performance when writing parallel programs for heterogeneous environments, and I'm looking for good candidate programs to port to SYCL which will exercise its C++ features. Can anyone suggest any good examples of open source libraries …

Member Avatar for mike_2000_17
0
254
Member Avatar for Shamar_1

Write a C++ program that accepts four quizzes (30%), two midterms (40%) and a final (30%) and displays the overall average. The maximum score for all quizzes and exams is 100 points.

Member Avatar for rubberman
-1
247
Member Avatar for Shamar_1

Write, compile, and execute a C++ program to calculate the sum of the numbers from 1 to 100. The formula for calculating this sum is sum = (n/2)(2*a + (n-1)d), where n = number of terms to be added, a = the first number, and d= the difference between each …

Member Avatar for David W
-2
171
Member Avatar for cambalinho

think in these way: the eyes have the blue color, the backcolor is blue. so how can i change the backcolor without change the image\eye? (these is just an exemple for trying explain)

Member Avatar for cambalinho
0
152
Member Avatar for cambalinho

heres my image class: class image { private: ULONG_PTR m_gdiplusToken; Gdiplus::GdiplusStartupInput gdiplusStartupInput; HDC hdcimage=CreateCompatibleDC(NULL); HGDIOBJ obj=NULL; HBITMAP btBitmap=NULL; Image *img; bool isimgused=false; int imageheight=0; int imageweight=0; int framecount=0; int intSelectFrame=0; int framedelay=0; string strfilename=""; Gdiplus::Color clrBackColor=Gdiplus::Color::Transparent; HDC hdcwindow; bool blnTransparent=true; HICON HICONFromHBITMAP(HBITMAP bitmap) { BITMAP bmp; GetObject(bitmap, sizeof(BITMAP), &bmp); HBITMAP …

Member Avatar for Schol-R-LEA
0
296
Member Avatar for iikitty

The first few digits are always "0"s and the last is "1"... I tried calculated on paper many times according to the steps in the code which I believe its logical and smooth. However it outputs "0"digits in front and "1" at last for every execution and I dun know …

Member Avatar for iikitty
0
314
Member Avatar for David_53

can anyone please explain different with vector::begin() and std::begin() ?? the code is based on the book, Effective Modern C++ item13. #include <iterator> #include <boost/type_index.hpp> using namespace boost::typeindex; #define PRINT_TYPENAME(__param) do { \ std::cout << "param (" << #__param << ") " \ << type_id_with_cvr<decltype(__param)>().pretty_name() \ << std::endl; \ } …

Member Avatar for vijayan121
0
352
Member Avatar for NoobCoder85

Here is my code: ` #include <iostream> #include <iomanip> #include <string> using namespace std; class Register { //Private members private: //Creating an array for all the Prices static double Price[]; //Declaring RegNUM and RecNUM int RegNUM, RecNUM; //Print out Item name in a loop static string items[]; //Creates a Receipt …

Member Avatar for David W
0
372
Member Avatar for Omar El Hussein

I've learned the basics of c++ Now, I want to develop and enter the graphics world, Any suggestions?

Member Avatar for マーズ maazu
0
182
Member Avatar for Yardood

Can someone please recommend me on a right way of working with codes? how should i plan it? how should i arrange it? every time i start a project i find myself later struggling with the difficulties of an unplanned project. how do YOU do it?

Member Avatar for Yardood
0
162
Member Avatar for JustinCpE

Good Day Sir, I am practicing on how to program something using do...while loop. I want to make a program that will ask for the Prelim, Midterm, Finals and Semestral Grade. 70% is the passing rate in our University. What are the codes that I have to put in C++?

Member Avatar for rubberman
-1
254
Member Avatar for marcelmarcelmarcelmarcelmarcelmarcelmarcelmarcel

Hello, for a school assignment I was supposed to write an insertion sort algorithm for a doubly linked list. As the feedback system of this particular course is rather weak (actually non-existent) I would like to ask you for your honest opinion about how well this is implemented, what could …

Member Avatar for David W
0
2K
Member Avatar for Yara Emad

Why it keeps giving me a zero answer ?!!! even though there IS a text file to search in it !! //a C++ project that reads a text from an input file and writes the same text into an output and find how much symbols are there #include <iostream> #include …

Member Avatar for David W
0
488
Member Avatar for Nanyo

Hi does anyone know if it is possible to use bruteforce to check for a username and a password in a website using C++? If yes please provide some code. Thanks! (Oh, and I am going to use that with educational purposes only) :D

Member Avatar for Nanyo
0
81
Member Avatar for Christina_3

Hi, I was assigned a project to write a user information program to help create and maintain user data. One of the parts of the project I am completely stumped on is how to validate the password a user would input... Tasks are... Evaluate Password - If either of the …

Member Avatar for Moschops
0
233
Member Avatar for bidisha_1

question related to C++ 1) Find the sum of natural numbers from 1 to 10. 2) Accept n numbers and find total of divisible by 5 and not by 10.

Member Avatar for rubberman
0
109
Member Avatar for SwtNemesis

Hello, I need to write a program that calculates how many days from year January 1, 0000 to any specified date including leap years. When I run the program that I have, I am off by a few days for any given date. Can someone please check out my code …

Member Avatar for David W
0
2K
Member Avatar for NoobCoder85

The tools Hal’s sells are: Hammers: $10.99 Wrenches: $10.99 Levels: $19.99 Tape Measures: $4.99 Screwdrivers: $8.99 In order to make things easier in the long run you have decided to make a c++ program that takes in all the orders for each register and tallies them at the end of …

Member Avatar for NoobCoder85
0
1K
Member Avatar for Piotr_13

I hope it's right place for it, if no - sorry, please tell me where I should place it. I wrote simple time class, could you review it, tell me what I did good, what wrong, and how I can fix it? I excluded things like include guards, namespaces, include …

Member Avatar for Piotr_13
0
217
Member Avatar for TObannion

So I was given a stack program to convert from int to char. I converted it but the output is...not expected. Wanting someone to point me in the right direction. I will post the header and driver program of the int stack and then the header and driver of the …

Member Avatar for NathanOliver
0
329
Member Avatar for mike_2000_17

This tutorial is the first time I write about coding techniques for improving the performance of software. This is going to be a step-by-step journey through a real example, with real benchmark results at every step so that you can see the effect of the different optimization techniques. And as …

Member Avatar for NathanOliver
7
2K
Member Avatar for Jazmine_1

Hey everyone so here's a new code and it compiles but it won't let me separate the data and add more questions for the user. Please help me and thanks in advance! I need it to enter 3 elements after list2 header file #ifndef H_myArray #define H_myArray class myArray { …

Member Avatar for David W
0
259
Member Avatar for senait.kifle.127

Hello Guys, I am trying to implement a coparison operator == into a try catch block to compare to clocks. I defined my comparator as friend bool operator ==(Clock&c1,Clock&c2) { return(c1.get_hour()==c2.get_hour() && c1.get_minute()==c2.get_minute()); } and my try catch block as Clock *clock3; try{ int hour,minute; cout<<"Hour: "; cin>>hour; cout<<"Minute: "; …

Member Avatar for mike_2000_17
0
234
Member Avatar for surya777

#include<iostream.h> void main() { int i=o; i=400*400/400; cout<<i; } i am getting a wrong output

Member Avatar for NathanOliver
0
141
Member Avatar for kellnerq

Hi together i need your help... again for my lab work. The question is the following: Use a single-subscripted array to solve the following problem. A company pays its salespeople on a commission basis. The salespeople receive £200 per week plus 9 percent of their gross sales for that week. …

Member Avatar for Victim_1
0
3K

The End.