So here's that piece of code, very basic but i just can't find any similar questions that have two variables in the while loop with cin in it. Can' ...
So here's that piece of code, very basic but i just can't find any similar questions that have two variables in the while loop with cin in it. Can' ...
Here is the question from Kaggle. I tried it using a while loop but I guess I am missing something basic here. The commented code using while loop i ...
While loop is not printing the question when the code catches ZeroDivisionError or ValueError. There are 2 functions called main() & convert() and ...
I want the user to select a number 1-7 and then check if that this is true, if not then they input a number again. I am able to check this but if a w ...
I want to make program which a has button , when we click on button , it will run some functions infinitely and the button turn into another button su ...
Caesar Cipher This is a Caesar Cipher program from Angela Yu's Udemy course on Python. The idea at the bottom is simply to allow the user to progre ...
User input range for num of rooms is [1-8]. Invalid input for this should display 'invalid input' and keep reprompt until receive valid input for exec ...
This is being tested on Zybooks, and everything I have tried has resulted in the program timing out. I can't figure out why! I think my while loop i ...
The challenge is to use Python to create a function that takes in sub-lists of a list and applies the strip function to each sub-list iteratively. Aft ...
When I am using for loop it's working perfectly but when I try to run this code with while loop and it's stuck loading. // for (var i = 0; i ...
I'm new to programming, and I try to program a menu in C++. I want it to be in a while loop, breaking when ESC is pressed, but I want the character t ...
I am a Java beginner. I am writing a method that should iterate through every possible value of a byte array, but the limit for each byte number in th ...
I have created the below bank project where the while loop is always taking the total amount as 100 and continue the loop as long as user select 'yes' ...
I'm printing out lowest tax from my project, but I'm stuck on this problem. How can I change this output: To this: Here is my code: ...
I am using a sensor that provides float data. In case of a faulty measurement the sensor also sometimes returns a "None" value. I would like to collec ...
Rolling summation. Determine the terminal value of y. While y is less than the threshold, add 0.01*(𝑦−𝑦2) to the old value of y. I tried this. ...
1 2 3 4 5 6 7 8 9 9 8 7 6 5 4 3 2 1 1 2 3 4 5 6 7 8 8 7 6 5 4 3 2 1 1 2 3 4 5 6 7 7 6 5 4 3 2 1 1 2 3 4 5 6 6 5 4 3 2 1 1 2 3 ...
I have a dataset and a vector of column names that I want to apply within a while loop. I can write code so it will put the number of iterations in th ...
I have a data structure that is essentially a linked list stored in state. It represents a stream of changes (patches) to a base object. It is linked ...
How can I make the code stop when the input<0 and when the lowest tax is the same. I have 4 countries and for example if Denmark and Norway have th ...