i need some help with this


Java programing

I Need Some Help With This Java Programing

Answers

Answer 1

def digit_sum(number):

 sumOfDigits = 0

 while number > 0:

     sumOfDigits += number % 10

     number = number // 10

 return sumOfDigits

or you can use,

In [2]: digit_sum(10)

Out[2]: 1

In [3]: digit_sum(434)

Out[3]: 11

or you can use,

digits = "12345678901234567890"

digit_sum = sum(map(int, digits))

print("The equation is: ", '+'.join(digits))

print("The sum is:", digit_sum)

Have a great day <3


Related Questions

Leland wants to work in a Production career operating heavy machinery. Which type of education or training should Leland seek?

a bachelor’s degree then a master’s degree
vocational school certificate or master’s degree
on-the-job training or vocational school certificate
associate’s degree then a bachelor’s degree

Answers

Answer:

it is indeed C

Explanation:

Answer:

c

Explanation:

Air at 25 m/s and 15°C is used to cool a square hot molded plastic plate 0.5 m to a side having a surface temperature of 140°C. To increase the throughput of the production process, it is proposed to cool the plate using an array of slotted nozzles with width and pitch of 4 mm and 56 mm, respectively, and a nozzle-to-plate separation of 40 mm. The air exits the nozzle at a temperature of 15°C and a velocity of 10 m/s.

Required:
a. Determine the improvement in cooling rate that can be achieved using the slotted nozzle arrangement in lieu of turbulated air at 10 m/s and 15°C in parallel flow over the plate.
b. Would the heat rates for both arrangements change significantly if the air velocities were increased by a factor of 2?
c. What is the air mass rate requirement for the slotted nozzle arrangement?

Answers

Answer:

a. 2.30

b. decreases with increasing velocity.

c. 0.179 kg/s.

Explanation:

Without mincing let's dive straight into the solution to the question above.

                                                         [a].

The improvement in cooling rate that can be achieved using the slotted nozzle arrangement in lieu of turbulated air at 10 m/s and 15°C in parallel flow over the plate can be determined by calculating turbulent flow:

The turbulent flow over the plate= 10 × 0.5/ 20.92 × 10⁻6 = 2.39 × 10⁵.

While the turbulent flow correlation = 0.037( 2.39 × 10⁵)^[tex]\frac{4}{5}[/tex] (0.7)^[tex]\frac{1}{3}[/tex] = 659.6.

Array of slot noozle = [10 × (2  × 0.004)]/ 20.92  × 10^-6] = 3824.

where A = 4/56 =0.714.

And Ar = [ 60 + 4 (40/2  × 4) - 2 ]^2 ]-1/2 = 0.1021.

N = 2/3 (0.1021)^3/4 [ 2  ×  3824/ ( 0.0714 / 0.1021) + (.1021/0.0714)] (0.700)^0.42 =24.3.

h = 24.3  ×  0.030/0.004 = 91.1 W/m^2k.

Therefore; 659.6  × 0.030/0.5 = 39.0 W/m²k.

The turbulent flow = 0.5 × 39.6 × 0.5( 140 -15) = 1237.5 W.

The slot noozle = 91.1  ×  0.5  ×  0.5 [ 140 -15] = 2846.87W.

The improvement in cooling rate = 2846.87/ 1237.5 = 2.30.

                                                     [b].

2.3 [ (2^2/3)/ 2^4/5] = 2.1

Thus, it decreases with increasing velocity

                                                      [c].

The  air mass rate requirement for the slotted nozzle arrangement = 9 × 0.995 (0.5 × 0.004)10 = 0.179 kg/s.

After earning a bachelor's degree, one must do which of the following before taking the PE examination to receive a Professional Engineering license?

Answers

FUNDAMENTALS OF ENGINEERING (FE) Exam and get the EIT license