Basically I'm EXTREMELY new to java, I'm struggling HARD CORE I've gotten this far
public class Song {
//Instance field
private String Maker;
private String Name;
private int Length;
private String Type;
private int yearReleased;
//0 Arg
public Song() {
Maker = "Logic";
Name = "1-800";
Length = 4;
Type = "Hip Hop";
yearReleased = 2017;
}
//Multi Arg
public Song(String Maker, String Name, int Length, String Type) {
this.Maker = Maker;
this.Name = Name;
this.Length = Length;
this.Type = Type;
this.yearReleased = yearReleased;
}
public String getyearReleased() {
return Song;
}
public void setName(string name) {
this.yearReleased = yearReleased;
}
public String getyearReleased() {
return yearReleased;
}
//Method
public String toString() {
String output;
output = "The artist of this song is " + Maker + "\n" +
"The name of this song is called " + Name + "\n" +
"This song is " + Length + " Minutes long" + "\n" +
"The genre of this song is " + Type;
return output;
}
}
I already made the driver. Yes this will have an error, I also need to add convertMinToSec() but what is happening? how do i properly set up the getters setters AND the convert to min sec?
You know when your teacher starts off at 2+2 you look away and look back and they are at 2>(2+2)^8 = x/5*3ve+32% Yea,I would compare this to that.
Someone please help me by telling me how to properly set up getters setters and convert min to sec. I have already tried to properly set but failed miserably.
My expected result is for it to recall the output correctly and the year released but it doesn't it errors by saying incorrect symbols, this is my first time making a post so I know it's going to seem absolutely stupid, but to me it's not, I looked online and couldn't find good content about this, I'm relying on you guys to show noobies like me the ropes when I don't know something! Thank you for taking your time to answer if you answer.