yeah I was trying to scale the data to look better on the program that my school offers. What I ended up doing was changing the list to an integer, like so.
int(Col1[b]) * -3
which worked when I was using a positive data scheme. My new problem seems to be when working with negative data input it gives me an error. Should I just change it to float, will that work for negative numbers used as input through the list.
User Profile
Collapse
-
-
Multiplying a list object with a negative integer.
Hi all, I m fairly new to programming so I am sorry if this is a simple answer. I am writing a program that creates a bar graph using a list of numbers. I am having problems multiplying the list object, which are all integers below 16. The reason I am multiplying is to get a clearer visualization of the graph, here is the code.
...Code:Col1 = [9, 10, 14, 9, 4, 3, 6, 5, 5, 2] Bwid = 100 b = 0 xpivot = 32 while
No activity results to display
Show More
Leave a comment: