- Strength to Increase Rep
- +0
- Strength to Decrease Rep
- -0
- Upvotes Received
- 3
- Posts with Upvotes
- 3
- Upvoting Members
- 1
- Downvotes Received
- 3
- Posts with Downvotes
- 3
- Downvoting Members
- 3
84 Posted Topics
"Write a program that reads in ten numbers to an array. The program then reads the array and displays distinct numbers (i.e. if a number appears multiple times, it is displayed only once)" for example: 1 2 3 4 [B]5 5 [/B]6 7 [B]8 8[/B] 9 1 2 3 4 … | |
In this Quicksort algorithm, it uses the pivot in the first location of each list. I am having difficulty understanding how to do this algorithm. When I look at examples online, and work out the problem(s) myself, it seems like the book does it differently, and I'm not sure what … | |
Pick a "c" and "n" for the problem below. f(n) = 2nlgn, g(n) = n^2-n My answer is below, but I am not sure if I am correct. I've been trying to figure out this same problem for a while. [B]The real solution is at the bottom, but I don't … | |
I receive the correct results when I use Microsoft Internet Explorer. However, when I use Ubuntu and try to get the output, I receive a blank screen except for the title "Book Finder Search Results" which appears at the top. Are there any adjustments I can make, so I can … | |
Is there a way to create a program to rewrite a query in an optimal form. If so, how? What can I do to implement this. Rewrite SELECT EMPOYEE.EMPNO, POSITION FROM EMPLOYEE E, JOBHISTORY J WHERE E.EMPNO = J.EMPNO AND STARTDATE <= ENDDATE AND SALARY <= 3000 into SELECT EMPLOYEE.EMPNO, … | |
I want a user to enter the query: "select * from books where price > 24.99 and price >= 25.00" for example, but since the statement doesn't need price >= 25.00, I want to rewrite the query to just "select * from books where price > 24.99" and give the … ![]() | |
Is there a way to create a C++ program to rewrite a query in an optimal form without the use of a database such as storing information in arrays. If so, how? What can I do to implement this. Rewrite SELECT EMPOYEE.EMPNO, POSITION FROM EMPLOYEE E, JOBHISTORY J WHERE E.EMPNO … | |
Is there a way to create a program to rewrite a query in an optimal form. If so, how? I already connected MYSQL to Java. I just need ideas on how to implement it. Thanks. Rewrite: SELECT EMPOYEE.EMPNO, POSITION FROM EMPLOYEE E, JOBHISTORY J WHERE E.EMPNO = J.EMPNO AND STARTDATE … | |
I am using dijkstra's algorithm to try to gather fake street names and find the shortest path. However, I can only get numbers to work instead of strings... The example of my results is below. [B]Results:[/B] The shortest route from 0 to 1 is : From Street 0 to Street … | |
Hi I am trying to compile and run my prog3.c program, but I am getting the compiler errors below. I have tried to reference the information by doing #include "node0.c" etc., but no luck. Any ideas on how to fix this problem? I attached the files below that I am … | |
Hi I am trying to compile and run my prog3.c program, but I am getting the compiler errors below. I have tried to reference the information by doing #include "node0.c" etc., but no luck. Any ideas on how to fix this problem? I attached the files below that I am … | |
My program is created to output permutations. Depending on the input that I put in, I sometimes get the correct result, but it is not accurate. However, when I do "abc", I get the correct result. When I input peoples names, I get a random result. After trying to figure … | |
In my program below, I am having problems running my program. The error I receive is "could not convert `nextPermutation(((char*)(&elements)), n)' to `bool'" I just want to print out the permutation of ABC. Will someone please check my nextPermutation function to see if everything is correct. I know there a … | |
Hello, I am having a difficult time getting my Binary Search Tree class to compile. I added 2 functions "add" and "search". Before I added the 2 functions. It compiled successfully. If someone can help me in the right direction. I will definitely appreciate it! [B]2 Functions:[/B] [CODE=Java] public BTNode<E> … | |
Hi, I'm having trouble getting age 10 occurrences and then removing age 10 from the list. Then I want to be able to print the list without displaying age 10 in it. I trying to use my bag class implementation to do this successfully. My bag class is below. Any … | |
First, I want to say that I am Java beginner and I do not have a lot of experience. This is my 2nd program. My objective is to write a program using stacks to see if a line inside of a file such as test.txt has matching scope symbols such … | |
Hey, this is my first java program. I am trying to print my original list of ages, but I can not figure it out. Please help! I have part b and part c already done. Any help is appreciated a) print original list of ages b) number of occurrences of … | |
hey, i wrote a program to create a hash table using an array of numbers, but I do not know how to display the actual table on my screen. Does anyone know how to display my results? So far, I am able to print the numbers that I have in … | |
I am writing program segments (not real programs or functions) to make sure if I understand how to do each one by using "push/pops for stacks" and "addQueue and DeleteQueue for Queues". Can someone please help me with these questions. I don't know if I am correct or not! 1. … | |
Hello, I need help reversing elements in a queue using Recursion. My problem is that when I print out the reverse, it does not show the numbers on the screen. However my program compiles and runs. My question is...How come the numbers in reverse are not showing? Thanks for anyone … | |
I need help with my print function, so I can print the elements in a queue. The print function, that I have now is the last function in my header file. I tried to do a small simple program to see if it works, but it prints nothing to the … | |
I am trying to determine if a word is a palindrome or not using queues, but I am receiving the wrong results. I have tried several things to get it to work using the boolean variable isPalin. Will someone lead me to the right direction please? I have been trying … | |
I recently have a thread open, but I feel it is starting to get too long, and the topic is kind of old since I have a new problem now. What I am trying to accomplish here is determining whether a word is a palindrome using queues. My program compiles … | |
Hello I am trying to determine whether a word is a palindrome or not using queues in my program below. However, I am currently having a problem. When I compile and execute my program, the output screen comes up and disappears very fast. Afterwards, I ran the program using the … | |
Hi all, I am trying to reverse the numbers in an array using recursion, however, I am receiving an error that I can't figure out. If possible, I need some assistance on it. [B]Error:[/B] line 27 incompatible types in assignment of `int' to `int[5]' [I]intArray = reverseArray(intArray,low,high);[/I] line 57 invalid … | |
I need help with the programming segments below, so I can study for them...I showed my effort on trying to do them. However, I don't believe they are right. If someone can assist me with this, I will definitely appreciate it. [B]1. Determine if a word is a palindrome or … | |
My question is, how do you calculate the "Completion Time" as I am alittle confused about it. Do I add the service times and the result is the completion times? Thank you to anyone who helps Jobs --- Service Time -- Arrival Time -- Wait Time J1 --- 2 --- … | |
My question is, how do you calculate the "Completion Time" as I am alittle confused about it. Do I add the service times and the result is the completion times? Thank you to anyone who helps [B]Jobs[/B] --- [B]Service Time[/B] -- [B]Arrival Time[/B] -- [B]Wait Time[/B] J1 --- 2 --- … | |
Hi. What I want to do is convert a postfix expression into a infix expression. I am reading the postfix expression from an input file and I want to print the infix expression to an output file. I basically just need help setting up my function, so it will work. … | |
I need help with my function that is in my stack.h file which converts postfix expression to infix. My main.cpp reads the postfix expression from a file and outputs the expression to an output file. My main.cpp is currently working. I just need someone to help me with my toInfix … | |
I need help trying to convert a postfix expression to Infix. I have tried to search books and internet material to help me take on this task but no luck. Below is what I created, but I know it is far from right which is why I appreciate if someone … | |
I had another thread before this one, but I felt that it was getting too long. Current problem: My operator== is not working properly in my program. I have done some things in my function, but I don't think it is "completely right". My program compiles fine and the output … | |
Can someone help me determine if 2 stacks are the same? I am fairly new to stacks and need help. My header file is also below. Currently I am getting an error message using "==" and "!=" in my if statement. If someone can help, I will appreciate it! Thanks … | |
Hello, I need some advice to help me write a program to convert postfix to infix. However, I am having difficulty getting started. I tried to search for more information, but all I got was infix to postfix results. This is what I have so far, but I want to … | |
In my header_inner, I am trying to display an image in the background, but whenever I try, it just shows the blank. Will someone please help me with this as I have been messing with this for hours. I posted a .doc to show how I want the image to … | |
Hi, I am new to stacks and need some help getting started with my first program in stacks. I have all the functions like pop,push etc. in my header file. I have to create a palindrome program with the objectives below. If someone can give me an idea on how … | |
I started a new thread since my last thread was getting to long. I am using stacks to find out if a string of characters is a palindrome, is not a palindrome, and is almost a palindrome. However, my output comes up and then disappears when i compile. So far, … | |
I am creating a diamond but I am having problem. Right now, my output prints out 2 triangles underneath each other (is not displaying in the post correctly). I want to flip the 2nd triangle around to create a diamond shape. However, when I try to mess up with counters … | |
Re: <cstdlib> [url]http://www.cplusplus.com/reference/clibrary/cstdlib/[/url] <iostream> [url]http://www.cplusplus.com/reference/iostream/[/url] | |
I am currently having problems with my getline in main. Whenever I use it, it prints out the last word in my input file twice. I do not know how to get rid of it. Any help is appreciated. [B]Input file:[/B] noon dog race car cat mom bob [B]Current Output:[/B] … | |
Hey, In my duplicateWords function, I have been trying to figure out for a couple of hours how to [U]create[/U] duplicates for 4 different names in the list. Will someone help lead me in the right direction in how to complete this task? My program is reading in 50 words … | |
Hi, I am currently having problems in my upperCase function. For 20 words out of 50 in my input file, I want to capitalize the first letter. Can someone please help me with this and lead me to the right direction. I have been trying for hours to figure it … | |
Hello. I'm having a hard time finding which block of code in this program is [B]"insert in the middle"[/B] for Link List, so I can study it. Can someone point out where it is in the program and if insert head code below is included in insert middle. Much appreciate … | |
Hi, I created an array of numbers which converts into letters through a number generator. I need help sorting my array letters[j] so that the output can be printed in alphabetical order. After, I am storing it in a Linked List and printing it out. So far, it just prints … | |
Hello I am trying to figure out how to create a number generator to generate a number between 65-90 (ascii capital letters) and 97-122 (ascii lowercase letters). I need to convert the number to a char and then put the char in the linked list in order while ignoring duplicates. … | |
Hi, I have two seperate programs below writing a short program for each. My programs run, but sometimes when I rearrange things in my program to try to get it to work, I will receive an error. I am tried to figure it out since last night, but I am … | |
Hello all. I am currently working on creating a program of a Checking Account and Savings Account. I am using my input file for deposits and withdraws. However, for my deposit and withdraw functions, I am unsure what to put in it. For those functions, am I suppose to read … | |
Hello, I need help printing my results to an output file with the program that I have below. I am getting an error "too few arguements to function". It has been a couple of years since I did C++ using .txt, so any help is appreciated. Thank you. [B]Goals:[/B] - … | |
Thank you for your reply. Problem solved! |
The End.