*** Systems *** OS: Windows 8.1 64bit IDK: MS Visual Studio Express 2013 for Windows Desktop Problem: I created a simple (very simple) User-defined function named func_compare that compares two numbers, it has two parameters of type Integer. It has no errors whatsoever until you compile it, and it says identifier func_compare not found. It seems to me that my compiler does not know that it was actually a user-defined function. I am also suspecting that my IDK is missing some components??? Here is my code; __________________________________________________________________ #include <iostream> using namespace std; int main(){ int num1, num2; cout << "Enter …

Member Avatar
Member Avatar
+0 forum 2

I'm trying to write a program that will ask the user to input the number of values he wants, prompt him for the values and then print out the maximum value and the minimum value. This is what I have so far: count=1 echo "Enter number of integers" read n while [ $count -le $n ] do echo "Enter integer" read x current=$x if [ $current -gt $x ]; then max=$current fi if [ $current -lt $x ]; then min=$current fi done echo "Max value is $max" echo "Min value is $min"

Member Avatar
Member Avatar
+0 forum 2

Hi, I kind of need help with my homework. I already have a code but it doesn't seem to work. I'm confused about the parameters I put. I don't know which part I actually messed up. I don't know what else to do. Thank you so much in advance for your help :] [CODE]#include <iostream> #include <string> #include <fstream> using namespace std; //Function Prototypes float gPACalculation(char cGrade); string honorsDistinction(float fGPA); void summaryInformation(float fGPA, string sHonorsDistinction); //Declare Constants const int SENTINEL = 0; int main () { //Declare Variables ifstream inFile; //input file ofstream outFile; //output file char cGrade =' '; …

Member Avatar
Member Avatar
+0 forum 8

Hello! I am working on a server program that has a connection to a MySQL database. In one of my sql:s i need to use [URL="http://dev.mysql.com/doc/refman/5.0/en/user-variables.html"]User-Defined Variables[/URL] but i can't get it to work. The sql looks something like this: [ICODE]"SET @rank=0; SELECT id FROM (SELECT @rank:=@rank+1 AS rank ..."[/ICODE] I'm wondering if it's not possible to have two "statements" ending with ";"in one PreparedStatement. When i run the sql in phpMyAdmin it works but from the server i get an exception: [ICODE]com.mysql.jdbc.exceptions.jdbc4.MySQLSyntaxErrorException: You have an error in your SQL syntax; check the manual that corresponds to your MySQL server …

Member Avatar
Member Avatar
+0 forum 5

Hey Guys I was wondering if anyone can help me with this assignment like completely walk me through it? I would really greatly appreciate it....... I have tried doing it and have came up with nothing. I have been having a lot of trouble understanding this material this school year. Here is what I have to do: 1. Create a user-defined data type (class) to represent a movie. A movie has several characteristics. You need to represent at least the following: 1) Title 2) Year 3) Director 4) Genre Provide at least the following functions: 1) Constructor that takes the …

Member Avatar
Member Avatar
-1 forum 3

HI I am working on a project to animate user-defined algos. I am still at the very beginning but I am practicing code in swing and here is an Array class that the user can use in his user defined algo: [CODE] import java.awt.*; import javax.swing.*; public class Array1 extends JPanel { int size = 0; int count = 0; int[]hold; public Array1(int[]arr) { size=arr.length; hold = arr; } public void paintComponent(Graphics g) { super.paintComponent(g); Graphics2D g2d = (Graphics2D) g; for(int i=1; i<=size; i++) { g2d.drawRect((i*30), 30, 30, 50); } for(int i=1; i<=size; i++) { g2d.drawString(Integer.toString(hold[i-1]), (i*30)+15, 55); } } …

Member Avatar
Member Avatar
+0 forum 1

Hi I have a project in which I have to build an algorithm visualization tool. Up until now I have been going in a static direction thinking of having in built menus that allowed a user to create an animation of a sorting algorithms but now my tutor wants me to make the tool more dynamic by allowing user defined algorithms that is my tool should be able to animate user defined algorithms. However I have no real idea of how to do this, I searched around a lot and guessed that I would allow the user to type the …

Member Avatar
Member Avatar
+0 forum 3

The End.