12 Solved Topics

Remove Filter
Member Avatar for
Member Avatar for Labdabeta

Hello, I wrote a library for arbitrary precision arithmetic recently and spent a long time implementing efficient multiplication algorithms. Now I am looking to see if it is possible for me to optimize anywhere else. One place that I thought should be more optimizeable is my division algorithm. Right now …

Member Avatar for mike_2000_17
0
1K
Member Avatar for JavaPrograms
Member Avatar for broj1

Hi folks. I have a strange thing happening here. I have a loop where counter gets incrememnted by 0.1 starting from 0 and up to 1. In each iterration I use the counter in an expression with modulo operator. I get incorrect result when the counter has values of 0.8 …

Member Avatar for DarkMonarch
3
387
Member Avatar for FALL3N

what I'm pretty sure I learned in school and what like every website said when I tried to look this up online was that the C++ code for generating a random number with floor: 1 and ceiling 100 (err I guess 101) is: [CODE]int number = rand() % 100 + …

Member Avatar for FALL3N
0
277
Member Avatar for Gold Falcon

Hello! To get straight to the point, I can't seem to get division to work. I haven't been programming in Assembly long, and I've been trying to get this to work for a couple of days now with no success. Anyway, here's my code: [CODE=assembly] section .text global _main extern …

Member Avatar for Gold Falcon
0
351
Member Avatar for Nerathas

Hello, I am trying to write a algoritm that calculates the second largest divisor of a number. But i have absolutely no idea what calculations are required for this. [CODE] for (ulong i = 1; i < Number; i++) { Number = .....? }[/CODE] Already know the largest common diviser …

Member Avatar for ddanbe
0
2K
Member Avatar for giftalp

I have created class menu and class number. I would like that my functions in class do sum, subtract, multiply, and divide. I've done sum, but I have problems with other functions. When I do difference, it is actually sum my numbers, and result of multiplication and division is 0 …

Member Avatar for giftalp
0
189
Member Avatar for Rickay

I am fairly new to programming but have been working on putting together a group of functions into one program. It is coming along nicely, but for some reason I can't get the loop on the divisibility function to work properly. When you prompt it to quit to return to …

Member Avatar for jonsca
0
154
Member Avatar for Griff0527

I am trying to edit my current homework assignment to include a loop that lets the user repeat the computation for new values until the user says they want to end the program. I was given a hint to use integer division and the % operator to implement this function. …

Member Avatar for NathanOliver
0
270
Member Avatar for MrBlack

in my code [B]Devide [/B]method is not working it gives an error "ExceptionHandling.Program.Devide(int, int)': not all code paths return a value" When i change public int Devide method in to void,the programe is workig , plz explain me what is the wrong with my code, im new to programming , …

Member Avatar for MrBlack
0
139
Member Avatar for apo

Hi, here is the thing, I'm trying to make my university grading table on C++, when i fill in the grades it should tell me what i have accumulate. the thing is that when i insert the text grades it shows a zero when i click the buttom. the math …

Member Avatar for apo
0
284
Member Avatar for asmhelp

Hello, I'm having a problem trying to trying to store a local variable in my asm program. I push 3 parameters: nbrElts (number of elements in the array), nbrArray (the address of the array), and result1 (the average). I'm trying to divide by the number of elements that I push …

Member Avatar for asmhelp
0
165

The End.