[Solved] Python take a variable number of inputs? [closed]

amount = int(input(“Enter the amount of numbers that you have: “)) numbers = [] for i in range(amount): new = input(‘Enter number {}: ‘.format(i+1)) numbers.append(new) print(numbers) You should probably do some reading on loops in Python. 2 solved Python take a variable number of inputs? [closed]

[Solved] How to create the table in javascript [closed]

Create basic elements like this: var myTable = document.createElement(‘table’); var tbody = document.createElement(‘tbody’); myTable.appendChild(tbody); then you can go in loop and append cells to tbody like this: var numberOfRows = 2; var numberOfCellsInRow = 5; for (var i = 0; i < numberOfRows; i++) { var tempRow = document.createElement(‘tr’); for (var j = 0; j … Read more

[Solved] Python – why is this wrong? [closed]

Luckily my crystal ball is working today so I can guess what you mean when you say it isn’t working. Of course, you might have made it easier by actually explaining, but there we go. If you just want a list of (x, y) pairs then zip is the way to go. The syntax you … Read more

[Solved] my website is a disaster on IE 9 and less [closed]

It looks like you need a doctype http://validator.w3.org/check?uri=http%3A%2F%2Fdev.ux-pm.com%2F&charset=%28detect+automatically%29&doctype=Inline&group=0 This will probably clear up quite a few issues with things looking wrong on older versions of IE but this won’t necessarily fix everything. Validating is not a cure all but I do find that the more compliant the code is then the less likely bugs occur. … Read more

[Solved] Backbone code not rendering simple View [closed]

Your problem is because you’re not waiting for the DOM to be ready, try moving the div like this (http://jsfiddle.net/icodeforlove/68gGS/) <body> <div class=”container”></div> <script type=”text/javascript”> var SearchView = Backbone.View.extend({ el: ‘.container’, initialize: function() { this.render(); }, render: function() { $(this.el).html(“hello”); //tried both but not working. this.$el.html(“hello”); } }); var search_view = new SearchView(); </script> </body> … Read more

[Solved] Implementation OOP in JAVA

Any of the following solutions will work: Remove the keyword, public from the definition of the classes, Circle and Square Write the classes, Circle and Square as they are (i.e. with public keyword) in separate files. The reason is that Java supports only one public class in a source file. A couple of more points: … Read more