1,112 Answered Questions for the topic computer programming

Computer Programming Computer General Computer Java

6d

Please help with coding problem

Hello,I have a question about a java code. I have to write a program where i'll enter a String value as a variable “word”: “blahblahblah” then create a method that is called “showPairs(String... more
Computer Programming Computer General Computer Java

11d

Help needed with code

I am struggling with a Java coding problem. How can I write an application that allows a user to enter any number of student quiz scores, as integers, until the user enters 99. If the score entered... more
Computer Programming

17d

Computer Programming

Do you think that C has all of the data types that a programmer needs to do his or her job? If so, why? If not, what is one data type you would add to the language to make it more useful?
Computer Programming

23d

Computer Programming

Goal: To bring together everything you've learned about repetition , relational operators, and input validation and show your mastery of these concepts.You are to write a program that will allow a... more
Computer Programming Java Computer Science Data

23d

Write a static method histogram() that takes an array a[ ] of int values...........

Write a static method histogram() that takes an array a[ ] of int values and an integer M as arguments and returns an array of length M whose ith entry is the number of times the integer i appeared... more
Computer Programming Java

24d

if Statement on two user inputs

import java.util.Scanner; public class RunBloodData { public static void main (String [] args){ Scanner sc = new Scanner(System.in); System.out.println("Enter blood type of... more
Computer Programming Computer C++ Computer Science

25d

Why is signed char 0xff = -1?

I don't understand it very well.
Computer Programming

27d

Computer Programming

Consider this excerpt of code that converts a temperature from Fahrenheit to Celsius:double fTemp = 75.2;double cTemp;cTemp = (5 / 9) * (fTemp - 32); 1. What is the problem with this code that will... more
Computer Programming Java Computer Science Javascript

10/26/21

BlueJ Questions

If you could write it in the format of BlueJ(Java). That would be great but if not that's ok1) Write programs with for loops that computea. The sum of all even numbers between 2 and 100... more
Computer Programming Computer Science Python Coding

10/25/21

Best Fit Algorithm Help

def BestFit(): boxes = readCSV() num_of_boxes = len(boxes) bin_area = 40 n_bin = 0 area_remaining_in_bins = [] lists = [] for x in range(num_of_boxes): ... more

10/19/21

program that counts from 1 through 100, and prints “D3” if the number is evenly divisible by 3

Write a C++ program that counts from 1 through 100, and prints “D3” if the number is evenly divisible by 3, “D5” if it’s evenly divisible by 5, “D3&5” if it’s even divisible by three and five,... more

10/15/21

Why is the answer O(N^2) for this big-o question?

For this question:Approximate the runtime of the following code fragment, in terms of n: Write your answer in a format such as "O(N^2)" or "O(N log N)".int sum = 0;for (int i = 1; i <= n; i++)... more

10/15/21

Is my thought process for a big-o question correct?

For this question:Approximate the runtime of the following code fragment, in terms of n: Write you answers in a format such as O(N^2) or O(N log N):int sum = 0;for (int i = 1; i <= n; i++) { ... more
Computer Programming Computer Java Web Design

10/07/21

Please help with Java code

How can I define a for loop for the following output:1+2 = 32+3 = 54+5 = 98+9 = 1716+17 = 3332+33 = 6564+65 = 129any help would be very appreciated
Computer Programming Python Programming

10/06/21

It should display stars, but it gives me an error

I am supposed to let the user enter number of rows and number of columns, but when I enter the rows and columns, it gives me this errorhttps://mrkzgulfup.com/uploads/163354717093041.jpgand it... more
Computer Programming

10/04/21

Flowchart represents the logical sequence that combines steps to be performed

Computer Programming C++ Computer Science Programming

09/29/21

C++. Create a program that helps keeping track of song lists. Include code.

This program is an exercise in building, traversing, and destroying linear linked lists. The use of recursion should be included at least once in each assignment to better prepare us for future... more
Computer Programming Computer Computer Science Coding

09/28/21

Next Fit Algorithm Help

def NextFit(): boxes = readCSV() num_of_boxes = len(boxes) bin_area = 40 n_bin = 0 area_remaining_in_bins = [] lists = [] for x in range(num_of_boxes): ... more
Computer Programming Java Computer Science

09/25/21

Removing an element from a circular linked list

Here I have my code that deletes a given integer value from a circular linked list: public void remove(int item){ Node temp = tail.next; //Refers to the first index Node... more
Computer Programming Computer Computer Science

09/24/21

Circular Linked List: indexOf(int)Return the location fo the first occurrence of the value in the list. Return 0 if it is the first item. Return -1 if the item is not in the list.

So throughout my code I did not keep track of the size of the list. My code does add and deletes, but I was wondering how I could implement code where I don't necessarily need the size of the list... more
Computer Programming C++ Computer Science

09/23/21

Basic C++ Question

Primary U.S. interstate highways are numbered 1-99. Odd numbers (like the 5 or 95) go north/south, and evens (like the 10 or 90) go east/west. Auxiliary highways are numbered 100-999, and service... more
Computer Programming Computer Science

09/18/21

Change the Computer class to a struct. 1. Keep the default and non-default constructors 2. Your struct does not need the accessors and mutators since all variables are public by default.

3.Also Perforom the following: Write a main(): - Create an instance of type Computer using the default constructor. - Set the values for year, model, and purpose using any values you'd like. -... more
Computer Programming Computer Science

09/17/21

Create three separate files for this code: 1. Computer.h holds the class' declaration 2. Computer.cpp holds the class' functions' definitions 3. Main.cpp holds the test code (i.e. the main function)

#include <iostream> #include <string> using namespace std; class Computer { private: int year; string model; string purpose; public: Computer(int y, string m, string m2)... more
Computer Programming Computer Science

09/16/21

Boolean Expression Grammar

Write a grammar for Boolean expressions , assuming that we already have rules in our grammar for arithmetic expressions . Arithmetic expressions might be simple literals like 3 or 97 or may be... more

Still looking for help? Get the right answer, fast.

Ask a question for free

Get a free answer to a quick problem.
Most questions answered within 4 hours.

OR

Find an Online Tutor Now

Choose an expert and meet online. No packages or subscriptions, pay only for the time you need.