Answer:
The solution is given in the attachments.
Answer:
The output will be (3, 4) becomes (8, 10)
Explanation:
#include <stdio.h>
//If you send a pointer to a int, you are allowing the contents of that int to change.
void CoordTransform(int xVal,int yVal,int* xNew,int* yNew){
*xNew = (xVal+1)*2;
*yNew = (yVal+1)*2;
}
int main(void) {
int xValNew = 0;
int yValNew = 0;
CoordTransform(3, 4, &xValNew, &yValNew);
printf("(3, 4) becomes (%d, %d)\n", xValNew, yValNew);
return 0;
}
Answer:
Output:-
Enter the five digit lottery number
Enter the digit 1 : 23
Enter the digit 2 : 44
Enter the digit 3 : 43
Enter the digit 4 : 66
Enter the digit 5 : 33
YOU LOSS!!
Computer Generated Lottery Number :
|12|38|47|48|49|
Lottery Number Of user:
|23|33|43|44|66|
Number Of digit matched: 0
Code:-
import java.util.Arrays;
import java.util.Random;
import java.util.Scanner;
public class Lottery {
int[] lotteryNumbers = new int[5];
public int[] getLotteryNumbers() {
return lotteryNumbers;
}
Lottery() {
Random randomVal = new Random();
for (int i = 0; i < lotteryNumbers.length; i++) {
lotteryNumbers[i] = randomVal.nextInt((50 - 1) + 1);
}
}
int compare(int[] personLottery) {
int count = 0;
Arrays.sort(lotteryNumbers);
Arrays.sort(personLottery);
for (int i = 0; i < lotteryNumbers.length; i++) {
if (lotteryNumbers[i] == personLottery[i]) {
count++;
}
}
return count;
}
public static void main(String[] args) {
int[] personLotteryNum = new int[5];
int matchNum;
Lottery lnum = new Lottery();
Scanner input = new Scanner(System.in);
System.out.println("Enten the five digit lottery number");
for (int i = 0; i < personLotteryNum.length; i++) {
System.out.println("Enter the digit " + (i + 1) + " :");
personLotteryNum[i] = input.nextInt();
}
matchNum = lnum.compare(personLotteryNum);
if (matchNum == 5)
System.out.println("YOU WIN!!");
else
System.out.println("YOU LOSS!!");
System.out.println("Computer Generated Lottery Number :");
System.out.print("|");
for (int i = 0; i < lnum.getLotteryNumbers().length; i++) {
System.out.print(lnum.getLotteryNumbers()[i] + "|");
}
System.out.println("\n\nLottery Number Of user:");
System.out.print("|");
for (int i = 0; i < personLotteryNum.length; i++) {
System.out.print(personLotteryNum[i] + "|");
}
System.out.println();
System.out.println("Number Of digit matched: " + matchNum);
}
}
Explanation:
Answer and Explanation:
The main objective that the torsion test serves is the determination of the material behavior or the behavior of the test sample when subjected to torsional stresses or forces due to the application of moments that results in shear stress along the axis.
Plasticity is the property of elastic material and tension or shear stresses leads to plasticity in a material where these links are the weakest, that gives torsion test a major advantage over the tension test.
Torsion tests are performed on materials to deduct properties like the shear modulus of elasticity, the torsional strength, and the MOR, i.e., Modulus of Rupture.
This test can be used to obtain larger strain values of strain without any complexity as that in tension test.
This test provides a curve of shear-stress-shear strain which is more significant in determining the plasticity as compared to the curve of stress-strain in tension test.
Maximum torque for a given value of maximum stress will be 2 times higher in torsion as that of tension.
In torsion, for plastic flow, the threshold value of shear stress is achieved before the threshold value of normal stress for fracture whereas in tension the critical value of normal stress is achieved sooner than the critical shear for plastic flow.
Answer:
Explanation:
Adjusting the distance between the two electrodes is called gapping your spark plugs. You need a feeler gauge to gap your spark plugs properly If you're re-gapping a used plug, make sure that it's clean (gently scrub it with a wire brush)
hope this you
Who is right?
Technician A says that the unitized structure of a hybrid vehicle is considerably different when compared to the same conventional model is right.
Hybrid vehicle are defined as a powered by a combustion engine and/or a number of electric motors that draw power from batteries. A gas-powered car simply has a traditional gas engine, but a hybrid car also features an electric motor.
One important advantage of hybrid cars is their capacity to reduce the size of the main engine, which improves fuel efficiency. Many hybrid vehicles employ electric motors to accelerate slowly at first until they reach higher speeds. They then use gasoline-powered engines to increase fuel efficiency.
Thus, technician A says that the unitized structure of a hybrid vehicle is considerably different when compared to the same conventional model is right.
To learn more about hybrid vehicle, refer to the link below:
#SPJ5
Answer:
ask someone u fool hhhhhhhh