#I need help uni work

1 messages ยท Page 1 of 1 (latest)

fallen driftBOT
#

<@&987246399047479336> please have a look, thanks.

carmine nimbus
#

I perfer a person for this

quasi hill
#

u did not post any question

#

no one can help u like that

carmine nimbus
#

I kinda perfer to keep it private I'm kinda humiliated

#

it's nothing complicated

quasi hill
#

we dont do private help here

#

post a concrete question and ull get help asap

#

๐Ÿ™‚

#

if ur just asking to ask u wont get help

carmine nimbus
#

it's the basics my professor doesn't explain well anf the code I write is not working so I kinda focused on the other subjects and now I have a 5 Labs I need to do in 48 hours

quasi hill
#

ur still asking to ask instead of asking an actual question

#

post ur "basic questions" and we will answer them immediately

carmine nimbus
#

I am explaining I'm not done

fallen driftBOT
#

For learning Java, we recommend the ebook Modern Java:
https://javabook.mccue.dev/

It is completely free, meant for beginners and covers all content relevant for the first year. It is a great way to learn Java from the ground up.
If you run into any questions during your journey, you may ask us in #1051826284008853505 and we will help cat_thumbs_up

If you prefer a more traditional learning experience, we also recommend MOOC:
https://java-programming.mooc.fi/
This is the course used by the University of Helsinki to teach their students programming in their first year, also completely free.

quasi hill
#

ur wasting time by ignoring my lead on this. im trying to get u to ur answers as fast as possible ๐Ÿ‘

quasi hill
carmine nimbus
quasi hill
#

i think ur not understanding

#

the way u try to ask for help will result in u not getting help

#

or at least not until ur out of time

#

i have many years experience helping people, including a lot of people in a rush

carmine nimbus
#

I don't understand what you are trying to tell me to ask

quasi hill
#

listen when i say that u get help the fastest way by putting in effort to make it easier for others to help u.
low effort posts like what ur doing now will get help very slowly only

quasi hill
#

step by step. the first question

#

share what u have, explain, guide us, elaborate

carmine nimbus
quasi hill
#

ur not asking a question

#

ur wasting time

#

be concrete, what exactly is unclear to you. what do you want an answer for

carmine nimbus
carmine nimbus
quasi hill
#

its been 20min now and u haven't asked anything that could be answered

#

ur constantly asking to ask

carmine nimbus
quasi hill
#

"can someone help me". the answer is yes. stop asking that and continue with the actual question

#

the helper here, ask them ur question

#

u have everyones attention since 20min. use it and ask a question ๐Ÿ™‚

carmine nimbus
#

I kinda want to call and share screen

#

idk how to put it to words

quasi hill
#

u might have to wait longer for that

carmine nimbus
#

ik ;-;

quasi hill
#

what is the first task ur stuck on. what is unclear to u specifically

#

whats the code u already have. what code do u not understand

#

which part of the task do u not understand

#

be concrete

#

right now its like ur calling the emergency and all ur saying is "i need help". and they are like "yes, what happened?" and u "i need help please" and they "where are you" and u "its so bad, i need help"

#

do u see how that doesnt work

#

anyways. its been 30min now, im out of time. cheers

carmine nimbus
carmine nimbus
quasi hill
#

u should use ur time to continue to provide details. there are many other helpers reading this chat who are just waiting to hop in as soon as u posted anything that can actually be helped with.
right now ur freezing like in panic or like giving up

#

which isnt exactly helpful to reach ur goals

#

like, now u posted some totally random screenshot. what is it that we are looking at? what is confusing u there? whats the issue? u gotta be more cooperative to this whole help thing ๐Ÿ™‚

#

especially if ur in a hurry

carmine nimbus
#

basicly the code is not running but I don't see any errors

lemme copy the code

#

public class UniversitySystem {

public static void main(String[] args) {
    
    Student s1 = new Student("S1001", "Ahmed", 3.6, 12); 
    
    System.out.println("Before adding credits:");
    
    s1.studentInfo();
    
    
    s1.addCredits(3);
    
    System.out.println("After adding credits:");
    
    s1.studentInfo(); 
    
    Student s2 = new Student();
    
    s2.setId("S1002");
    
    s2.setName("Sara");
    
    s2.setGpa(3.9);
    
    s2.setRegisteredCredits(15);
    
    System.out.println("Before dropping credits:");
    
    s2.studentInfo();
    
    boolean ok = s2.dropCredits(6);
    
    System.out.println("Drop credits result: " + ok);
    
    System.out.println("After dropping credits:");
    
    s2.studentInfo();
    
    Student.displayCount();

} 

}

#

-----------

#

public class Student {

private String id;

private String name;

private double gpa;

private int registeredCredits;


private static int count=0;

public Student(){
    
    count++;
    
}

public Student(String id, String name, double gpa, int registeredCredits) {


    
    this.id=id;
    
    this.name=name;
    
    this.gpa=gpa;
    
    this.registeredCredits=registeredCredits;
    
    count++;
    
    
 }

public String getId(){
    
    
    return id;
    
}

public void setId(String id){
    
    this.id=id;
    
}

public String getName(){
    
    return name;
    
}

public void setName(String name) {
    
    
    
    this.name = name;

}


public double getGpa() {
    
    return gpa; 

}

public void setGpa(double gpa) {
    
    
    if (gpa >= 0.0 && gpa <= 4.0) {
        
        this.gpa = gpa; 
    }
    
}

public int getRegisteredCredits() {
    
    return registeredCredits; 

}



public void setRegisteredCredits(int registeredCredits) {
    
    if (registeredCredits >= 0) {
        
        this.registeredCredits = registeredCredits; 
    
    } 
}


public void studentInfo() {
    
    System.out.println("Student ID: " + id);
    
    System.out.println("Student Name: " + name);

    System.out.println("GPA: " + gpa);

    System.out.println("Registered Credits: " + registeredCredits);
#

System.out.println("----------------------------");

}


public void addCredits(int hours) {
    
    if (hours >= 0) {
        
        registeredCredits += hours; 
    
    } 
}


public boolean dropCredits(int hours) {
    
    if (hours < 0) return false;
    
    if (registeredCredits - hours >= 0) {
        
        registeredCredits -= hours; return true; 
    
    } 
    
    return false; 

} 


public static void displayCount() {
    
    System.out.println("Number of students: " + count); 

}
#

this is to split these two

inland haven
carmine nimbus
carmine nimbus
inland haven
#

you are running student

#

but the main class is university system

carmine nimbus
#

hmmm how do I run the other one

inland haven
#

hmm

#

netbeans ?

carmine nimbus
#

I am required by the curriculum to use it

fallen driftBOT
#
TJ-Bot
How do you change the main class to run in netbeans ?

An error has occurred while trying to communicate with ChatGPT.
Please try again later.

inland haven
#

huh

carmine nimbus
#

I despise the app it doesn't provide as much assistance as in visual studio

inland haven
#

Can't you put yourself in university class

#

and click run ?

carmine nimbus
#

no ;-;

rare heron
inland haven
#

then try to edit run configurations

carmine nimbus
carmine nimbus
#

what is the problem here

carmine nimbus
carmine nimbus
#

nvm I fixed it

oblique forge
#

its an artifact of the editor also being for professionals - its kind of strange to explain

carmine nimbus
#

ummmm

oblique forge
#

like okay

#

when you mark a field as final

#

so private final int thing; as opposed to private int thing;

#

all that does is restrict you from doing something - in this case, re-assigning the field

#

so you can't write

#
public void setThing(int v) { 
    this.thing = thing; 
}
#

if a field is final

#

a common philosophy among professionals is to "lock down things as much as possible"

#

so the editor gives it as a warning

#

nothing is wrong with the code, but netbeans sees "this field could be final" and suggests it

#

and its fine if you do it - again it doesn't change anything

#

you just remove final later if you don't want that

#

its annoying for people learning since its just not relevant to you yet

carmine nimbus
#

it's more I don't want to send my work here

#

then me wanting to dm you

mint needle
#

I was required to use netbeans too but my prof didn't rlly care

oblique forge
#
  1. its past midnight, i'm only here because i'm binging gundam
#
  1. just share your stuff here, its fine
soft bobcat
#

i know anime mobile suit gundam

#

but i am sure, it is not related

oblique forge
soft bobcat
oblique forge
#

its the first one for me. wow they really committed with "the entire cast are child soldiers"