Recent content by thatguy101

  1. T

    Comp Sci How to Save and Sort a List of Historical Events in Java?

    So I was able to make the array go from latest event on down, but I can't find how to add 1892, or where my PrintWriter is writing to. Here's my newish code import java.io.*; import java.util.*;public class Assignment { public static void main(String[] args) throws FileNotFoundException{...
  2. T

    Comp Sci How to Save and Sort a List of Historical Events in Java?

    Thank you! I believe I have found a solution. Your help is very much appreciated!
  3. T

    Comp Sci How to Save and Sort a List of Historical Events in Java?

    The array events does get filled. I used a for loop with System.out.println(); to check it before I went on. As for the "if (event != 1892 && (readin.hasNext() == false))" I thought I might need that to let the program know that the year 1892 needs to be added to the list. Like I said, this is...
  4. T

    Comp Sci How to Save and Sort a List of Historical Events in Java?

    Homework Statement You are provided the following list that contains (semi-random) years from modern history. Save the list to a text file named “events.txt” Write a program that: 1. Reads in the file “events.txt” 2. Sorts it with the latest events first 3. Determines whether the founding of...
  5. T

    Comp Sci 100 Lockers Problem Java Program

    I did this because the inner loop is about the locker number. So the first locker would be lockers[0]. and to iterate that 100 times, it would need to stop at 99
  6. T

    Comp Sci 100 Lockers Problem Java Program

    Thank you for that, but unfortunately it has to be in Java It is the language we are learning in class.
  7. T

    Comp Sci 100 Lockers Problem Java Program

    . Homework Statement A school has 100 lockers and 100 students. All lockers are closed on the first day of school. As the students enter, the first student, denoted S1, opens every locker. Then the second student, S2, begins with the second locker, denoted L2, and closes every other locker...
  8. T

    Calculating Photon Momentum and Speed for a 1205 kg Spaceship with a Square Sail

    Homework Statement In space near earth, about 3.84*10^21 photons are incident per square meter. On average, the momentum of a photon is 1.3*10^-27. Assume we have a 1205 kg spaceship, and a square sail that is 26.3m wide. How fast could the ship be traveling after 21 days? Homework...
  9. T

    Atwood Machine: Acceleration of m1

    Homework Statement Three objects with masses m1 = 35.1 kg, m2 = 16.8 kg, and m3 = 10.5 kg are hanging from ropes that are redirected over pulleys. What is the acceleration of m1? Negative numbers for downward, and positive numbers for upward, please. Homework Equations F=ma...
  10. T

    Find Mass M1 Given Acceleration, Angle, and Friction

    Thank you. I figured it out. So I had Ft-mg*sinθ+μ*mg*cosθ=ma so Ft=mg*sinθ+μ*mg*cosθ+ma factor out the m, Ft=m(g*sinθ+μ*g*cosθ+a) then solved for m. and since Ft= m2g-m2a, I just put in the numbers and came up with 22.47 N amd just plugged in everything else into the equation above and...
  11. T

    Find Mass M1 Given Acceleration, Angle, and Friction

    Ok so my diagram looks like this. For m1 I have forces in the y direction as y: Fg*cosθ-Fn=0 And the forces in the x direction as x:Ft-Fg*sinθ-Ff=a. And then for m2 there are none in the x direction but for y I have y: Fg-Ft=ma. Am I right so far?
  12. T

    Find Mass M1 Given Acceleration, Angle, and Friction

    Sorry. It's suppose to say θ. m1 is on an incline of 20°, and m2 is hanging off the incline.
  13. T

    Find Mass M1 Given Acceleration, Angle, and Friction

    so then would I subtract gravity? Ft=3*2.31-3*9.81?
  14. T

    Find Mass M1 Given Acceleration, Angle, and Friction

    Homework Statement M1 and M2 are two masses connected as shown (M2 hangs over the table). The pulley is light (massless) and frictionless. Find the mass M1, given that M2 (3.0 kg) accelerates downwards at 2.31 m/s^2, q is 20°, and μk is 0.41. Homework Equations F=ma μn=friction...
Back
Top