213 Topics

Member Avatar for
Member Avatar for shubham.joy

What is the error in this simple code: [CODE]#include <stdio.h> int main() { char a[100]; int c; int i = 0; int x = 0; while( ( c = getchar() ) != '\n' ) { a[x++] =c; } a[x] = '\0'; while( ( a[i] != '\0' ) || ( a[i] …

Member Avatar for zeroliken
0
113
Member Avatar for borgyborg

I am having a looped form in my site, but i have a problem on saving it. I don't know where is my mistake. Please someone help me. i have 5 records. in my code it saves only one record. and its not giving the correct value. it shows "Array" …

Member Avatar for borgyborg
0
125
Member Avatar for 8367144q

I've got a worksheet which asks me to ask the user to enter a beginning and ending value. Create a for loop using these numbers. Also ask the user to enter another number. The program will search for multiples of this value. a. The total of all values in the …

Member Avatar for Moschops
0
142
Member Avatar for pwolf

okay, so i was doing an exercise for this beginning python course i got my hands on, and i just completed the exercise (took longer than it should have though) and for some reason, when i run it, it returns data i didn't expect, and when i run it again …

Member Avatar for pwolf
0
159
Member Avatar for cgray1989

I'm trying to figure out how to do this program. A program is required to print and read a series of exam scores for students enrolled in a math class. The class average is to be computed and printed at the end of the report. Score can range form 0 …

Member Avatar for jmichae3
0
135
Member Avatar for cgray1989

I'm trying to figure out how to do this program. A program is required to print and read a series of exam scores for students enrolled in a math class. The class average is to be computed and printed at the end of the report. Score can range form 0 …

Member Avatar for jackmaverick1
0
129
Member Avatar for LateNightCoder

In my program I read in a text file an decrypt the text from an array. once decrypted i then have to do through it again and search for every tenth array member and show their memory location. The code so far: [CODE] int main( ) { int* pCrypted = …

Member Avatar for LateNightCoder
0
292
Member Avatar for techlawsam

prompt: need the user to input 1st and last values for the table. DIsplay in a column in the table starting with 1st base value that was inputted. Last column has to the ending base value that was entered. I need to make 15 rows of computations. First row should …

Member Avatar for ddanbe
0
215
Member Avatar for JaffaApophis

Hello, I am trying to build a GUI with 2 textfields (1 for tutoring time & 1 for payment for session), a textarea (display the inputs in 2-D array & show report), and a few buttons (ENTER, RUN REPORT & QUIT). The two textfields are for the user to enter …

Member Avatar for JamesCherrill
0
446
Member Avatar for MediumSoda

I need some help with a code I'm writing. The user inputs some letters, a loop is ran to check if it's a vowel or consonant, then when the user is done it returns the total amount of vowels and consonants. The problem I'm having is the loop is suppose …

Member Avatar for MediumSoda
0
410
Member Avatar for megatron21

I am trying to print out a chess board on the console. The data structure i am using is a set of pairs. I am having trouble accessing the pair's elements. I do realize a map is probably better in this case but i am using somebody else's code so …

Member Avatar for gusano79
0
240
Member Avatar for IcyFire

I have an assignment to make a craps game in c. The program i wrote runs but it always ends before it should. I think that the while loops in main have a problem but im not exactly sure wat the problem is because ive reviewed this code over and …

Member Avatar for IcyFire
0
2K
Member Avatar for JRDJ12

I'm wondering if someone can help me figure out my getAverageLength method in the following code: [CODE]package com.abc.text; public class StringProcessing { /** * Returns the number of non-null strings in the set. * If null or a zero-length array is passed in, then zero is returned. * If a …

Member Avatar for Ezzaral
0
2K
Member Avatar for smallrubberfeet

Hello all, I'm having a bit of trouble logically figuring out what to do in this case for my cs150 class. I have to create a linked list from a while loop, but I can't figure out how to link the list successively at the end of each line so …

Member Avatar for Clinton Portis
0
2K
Member Avatar for gunnerone

I have this code: [CODE] foreach( $_POST[ 'count' ] as $textBoxIndex => $textBoxValue ) { echo '<br />Textbox ' . $textBoxIndex . ' has value [' . $textBoxValue . ']'; } [/CODE] This loops through a series of text boxes with have been created with this: [CODE] <while($rowequipment = mysql_fetch_assoc($sqlequipment)) …

Member Avatar for Rynkadink
0
86
Member Avatar for harde

Hi guys, So I write this program so far.. 1 //exercise15.cpp - displays a pattern of asterisks 2 //Created/revised by <harde> 3 4 #include <iostream> 5 using namespace std; 6 7 int main() 8 { 9 for (int outer = 2; outer < 11; outer += 2) 10 { 11 …

0
106
Member Avatar for theonebit

Hi, I would like some insigth or help on the following issue that i am facing. I am building an empty validation module. where i validate my bound item whether they are empty or or not before save. I have a tab control with the said bound items. The thing …

0
237
Member Avatar for A.D.M.I.N

I want to translate text inputted multiple times then output it. I am using the maketrans() function. I want to translate multiple times, by a number of times a user would input.

Member Avatar for woooee
0
298
Member Avatar for Blakeman321

Hi all, Ok so here's the deal, I work for a world wide recruiting company which has offices in multiple locations, for each office our sales team have a windows xp desktop connected to a flat screen(via VGA) displaying a power point presentation showing I.E. Most sales, annual income, blah …

Member Avatar for Blakeman321
0
249
Member Avatar for maynardjk13

Hello! I was given the following problem: Define the function f(x; y) as: f(x,y) = sqrt(x^2-y^2) Write a program that produces a table of f(x, y) for integers x and y from 0 to n where y <= x. The value of f(x,y) appears in row (x+1), column (y +1) …

Member Avatar for selina12
0
163
Member Avatar for Stefano Mtangoo

Hi, I was reading on the net and could not find how to implement as loop something like twig's [CODE] <ul id="navigation"> {% for item in navigation %} <li><a href="{{ item.href }}">{{ item.caption }}</a></li> {% endfor %} </ul>[/CODE] I want to have idea of what is going on!

Member Avatar for Stefano Mtangoo
0
159
Member Avatar for George_91

I've this code. I need to do several experiments to obtain de average time it takes to do some methods. Instead of re-running and re-running the program, I want to put a segment of the code in a FOR bucle. The problem is that my program never ends,it stays looping …

Member Avatar for vishwanath.m
0
165
Member Avatar for iamthesgt

This is homework. I was writing a bash script that accepts a list of group names on the command line and produces a group report detailing the group id and the number of group members identified in /etc/passwd for each group. Output will look like: Group Report Group GID Count …

Member Avatar for iamthesgt
0
303
Member Avatar for zack_falcon

Okay, so I have two arrays: [CODE]public int[] start = new int[21] { 0, 1, 1, 1, 1, 1, 1, 2, 3, 4, 5, 6, 7, 8, 9, 10, 11, 12, 13, 14, 14 }; public int[] end = new int[21] { 0, 1, 1, 1, 1, 1, 1, 2, …

Member Avatar for zack_falcon
0
176
Member Avatar for paulsoncall

Hi - I'm having a hard time figured out how to print the triangle shape below using loops. I did the two previous triangles with no issue but have no idea how to get the spaces in there. I'm really confused and would appreciate any help. [CODE] * ** *** …

Member Avatar for paulsoncall
0
258
Member Avatar for frost1

My problem is, I've just started with C# and i was given a problem to solve by my teacher... here is the code... [CODE] { class Program { static void Main(string[] args) { int[] a = new int[20]; Random rand = new Random(); for (int i = 0; i < …

Member Avatar for Ketsuekiame
0
435
Member Avatar for I am dumb

OK Im new to C++, I'm still a beginner, i know how to make simple calculations and all. But looping is completely different and I have no idea where to start: Here's all that I have for this question (Write an application that keeps inputting an integer from the user …

Member Avatar for gerard4143
0
237
Member Avatar for dakaboguy

Hello all, I have a form with 24 textboxes incremented by a letter. example: txtDimVala1.text, txtDimValb1.text, txtDimValc1.text, etc. I created a code to check each textbox, but there must me a more efficient way to loop it. I have tried a few loops but I cant get them to work …

Member Avatar for dakaboguy
0
698
Member Avatar for Prisms

Ok guys I'm almost done with my GPA program but I hit a snag. everything works fine but when I insert a letter grade the program doesn't read what number it corresponds to and sets double number to zero. Can some please let me know what I'm doing wrong. [CODE]import …

Member Avatar for Prisms
0
5K
Member Avatar for djjavo

Ok so I am creating this scoring game using motorsport drivers. The scores are in variables for example score.vettel is vettels score for the current gameweek. A player has 6 drivers d1,d2,d3,d4,d5,d6 which are in the variable player(x).d1 where x is the player number. Maxsize is the number of players …

Member Avatar for djjavo
0
152

The End.