1answer.
Ask question
Login Signup
Ask question
All categories
  • English
  • Mathematics
  • Social Studies
  • Business
  • History
  • Health
  • Geography
  • Biology
  • Physics
  • Chemistry
  • Computers and Technology
  • Arts
  • World Languages
  • Spanish
  • French
  • German
  • Advanced Placement (AP)
  • SAT
  • Medicine
  • Law
  • Engineering
Y_Kistochka [10]
3 years ago
5

I gave 15 min to finish this java program

Engineering
1 answer:
lisov135 [29]3 years ago
4 0

Answer:

class TriangleNumbers

{

public static void main (String[] args)

{

 for (int number = 1; number <= 10; ++number) {

  int sum = 1;

  System.out.print("1");

  for (int summed = 2; summed <= number; ++summed) {

   sum += summed;

   System.out.print(" + " + Integer.toString(summed));

  }

  System.out.print(" = " + Integer.toString(sum) + '\n');

 }

}

}

Explanation:

We need to run the code for each of the 10 lines. Each time we sum  numbers from 1 to n. We start with 1, then add numbers from 2 to n (and print the operation). At the end, we always print the equals sign, the sum and a newline character.

You might be interested in
Whats the pros about being in the army
Cerrena [4.2K]

Answer:

Benefits that last a lifetime. The Army offers you money for education, comprehensive health care, generous vacation time, family services and support groups, special pay and cash allowances to cover the cost of living.

8 0
3 years ago
Suppose we have a database for an investment firm, consisting of the following attributes: B (broker), O (office of a broker), I
Snowcat [4.5K]

Answer:

Given, FDs are:

S -> D

I -> B

IS -> Q

B -> O

a)

"I" and "S" must be there in any candidate key because they do not appear on the right side of any functional dependency.

The only candidate key is: IS

IS -> ISBDQO

b)

Decomposition of R into 3NF: (I, B), (S, D), (B, O), (I, S, Q)

c)

Decomposition of R into BCNF:

Decompose R by I → B into R1 = (I, B) and R2 = (I, O, S, Q, D).

R1 is in BCNF

Decompose R2 by S → D into R21 = (S, D) and R22 = (O, I, S, Q).

R21is in BCNF

Decompose R22 by I → O into R221 = (I, O) and R222 = (I, S, Q).

R221 is in BCNF.

R222 is in BCNF.

The decomposition is: (I, B), (S, D), (I, O), (I, S, Q)

We can also write it as: (I, B), (S, D), (B, O), (I, S, Q)

Explanation:

The answer above is rendered in a very explanatory way.

8 0
3 years ago
Refrigerant 134a enters an air conditioner compressor at 4 bar, 208C, and is compressed at steady state to 12 bar, 808C. The vol
SCORPION-xisa [38]

Answer:

heat transfer rate is -15.71 kW

Explanation:

given data

Initial pressure  = 4 bar

Final pressure  = 12 bar

volumetric flow rate = 4 m³ / min

work input to the compressor = 60 kJ per kg

solution

we use here super hated table for 4 bar and 20 degree temperature and 12 bar and 80 degree is

h1 = 262.96 kJ/kg

v1 = 0.05397 m³/kg

h2 = 310.24 kJ/kg

and here mass balance equation will be

m1  = m2

and mass flow equation is express as

m1 = \frac{A1\times V1}{v1}       .......................1

m1 = \frac{4\times \frac{1}{60}}{0.05397}  

m1 = 1.2353 kg/s

and here energy balance equation is express as

0 = Qcv - Wcv + m × [ ( h1-h2) + \frac{v1^2-v2^2}{2} + g (z1-z2) ]      ....................2

so here Qcv will be

Qcv =  m × [  \frac{Wcv}{m} + (h2-h1)  ]    ......................3

put here value and we get

Qcv =  1.2353 × [ {-60}+ (310.24-262.96) ]

Qcv =  -15.7130 kW

so here heat transfer rate is -15.71 kW

6 0
3 years ago
A shaft machined of AISI 1022 steel having σuts = 70 ksi and σy = 52 ksi is loaded cyclically. The loading is characterized by t
Maru [420]

Answer:

2.075 in

Explanation:

Please kindly check attachment for the detailed and step by step solution of the given problem.

3 0
3 years ago
The 2-lb block is released from rest at A and slides down along the smooth cylindrical surface. Of the attached spring has a sti
MA_775_DIABLO [31]

Answer:

L = 4.574 ft

Explanation:

Given:

- The weight of the block W = 2 lb

- The initial velocity of the block v_i = 0

- The stiffness of the spring k = 2 lb/ft

- The radius of the cylindrical surface r = 2 ft

Find:

Determine its unstretched length so that it does not allow the block to leave the surface until θ= 60°.

Solution:

- Compute the velocity of the block at θ= 60°. Use Newton's second equation of motion in direction normal to the surface.

                           F_n = m*a_n

Where, a_n is the centripetal acceleration or normal component of acceleration as follows:

                           a_n = v^2_2 / r

- Substitute:

                          F_n = m*v^2_2 / r

Where, F_n normal force acting on block by the surface is:

                          F_n = W*cos(θ)

- Substitute:

                          W*cos(θ) = m*v^2_2 / r

                          v_2 = sqrt ( r*g*cos(θ) )

- Plug in the values:

                          v^2_2 = 2*32.2*cos(60)

                          v^2_2 = 32.2 (ft/s)^2

- Apply the conservation of energy between points A and B where θ= 60° :

                      T_A + V_A = T_B + V_B

Where,

                      T_A : Kinetic energy of the block at inital position = 0

                      V_A: potential energy of the block inital position

                      V_A = 0.5*k*x_A^2

                      x_A = 2*pi - L            ..... ( L is the original length )

                      V_A = 0.5*2*(2*pi - L)^2 =(2*pi - L)^2

                      T_B = 0.5*W/g*v_2^2 = 0.5*2 / 32.2 *32.2 = 1

                      V_B = 0.5*k*x_B^2 + W*2*cos(60)

                      x_B = 2*0.75*pi - L            ..... ( L is the original length )

                      V_B = 0.5*2*(1.5*pi - L)^2 + 2*1 = 2 + ( 1.5*pi - L )^2

- Input the respective energies back in to the conservation expression:

                      0 + (2*pi - L)^2 = 1 + 2 + ( 1.5*pi - L )^2

                      4pi^2 - 4*pi*L + L^2 = 3 + 2.25*pi^2 - 3*pi*L + L^2

                      pi*L = 1.75*pi^2 - 3

                         L = 4.574 ft

                         

3 0
3 years ago
Other questions:
  • Sketch T-s and p-v diagrams for the Diesel cycle.
    8·1 answer
  • For laminar flow over a hot flat plate, the local heat transfer coefficient decreases with distance because (select all that are
    7·1 answer
  • Any help is appreciated.
    7·1 answer
  • A pump transfers water from a lake to a reservoir, which is located 29.2 m above the lake, at a rate of 11.5 L/s. Determine the
    12·1 answer
  • Which of the following best describes the relationship between the World Wide Web and the Internet? А The World Wide Web is a pr
    5·1 answer
  • Gtjffs
    5·1 answer
  • List all possible fracture mechanisms under which the unidirectional composites fail. Briefly explain and describe the related m
    7·1 answer
  • what do we call a landslide in which fine-grained soil moves cohesively but with extensive internal shearing?
    8·1 answer
  • Which material has the highest cp value?
    10·1 answer
  • Why doesn't any one give as many points as i do for random questions on brainly
    14·2 answers
Add answer
Login
Not registered? Fast signup
Signup
Login Signup
Ask question!