Answer:
In Python:
N = int(input("Positive integer: "))
if N > 0:
flag = False
for i in range(1,N+1):
if i * i == N:
flag = True
break
print(str(flag))
else:
print("Positive integer only")
Explanation:
N = int(input("Positive integer: "))
If the number is positive
if N > 0:
This initializes a boolean variable to false
flag = False
This iterates from 1 to the input integer
for i in range(1,N+1):
This checks if th number is a square of some integer
if i * i == N:
If yes, flag is set to true
flag = True
The loop is exited
break
This prints either true or false, depending on the result of the loop
print(str(flag))
If otherwise, that the number is not positive
<em>else:</em>
<em> print("Positive integer only")</em>
The first thing we are going to do is find the equation of motion:
ωf = ωi + αt
θ = ωi*t + 1/2αt^2
Where:
ωf = final angular velocity
ωi = initial angular velocity
α = Angular acceleration
θ = Revolutions.
t = time.
We have then:
ωf = (7200) * ((2 * pi) / 60) = 753.60 rad / s
ωi = 0
α = 190 rad / s2
Clearing t:
753.60 = 0 + 190*t
t = 753.60 / 190
t = 3.97 s
Then, replacing the time:
θ1 = 0 + (1/2) * (190) * (3.97) ^ 2
θ1 = 1494.51 rad
For (10-3.97) s:
θ2 = ωf * t
θ2 = (753.60 rad / s) * (10-3.97) s
θ2 = 4544,208 rad
Number of final revolutions:
θ1 + θ2 = (1494.51 rad + 4544.208 rad) * (180 / π)
θ1 + θ2 = 961.57 rev
Answer:
the disk has made 961.57 rev 10.0 s after it starts up
Answer:
It is an example of a matrix structure
Explanation:
The matrix structure is a structure in which jurisdiction, controls and duties are carried and uphold by a group of employees instead of just the manager.
In other words, employees have dual reporting relationships; they can give reports to the functional manager and they can also give reports to the product manager.
The Bennetton design selected by the network of Bennetton retail sales agents made activities to be easily coordinated because, they have collectively performed the duty as a unit and this is one of the advantages of this form of the matrix organizational structure.
Void test(char *s)
{
int i, d;
sscanf(s, "%i", &i);
printf("%s converts to %i using %%i\n", s, i);
sscanf(s, "%d", &d);
printf("%s converts to %d using %%d\n", s, d);
}
int main()
{
test("123");
test("0x123");
return 0;
}
outputs:
123 converts to 123 using %i
123 converts to 123 using %d
0x123 converts to 291 using %i
0x123 converts to 0 using %d
As you can see, %i is capable of parsing hexadecimal, whereas %d is not. For printf they're the same.