Welcome to Incels.is - Involuntary Celibate Forum

Welcome! This is a forum for involuntary celibates: people who lack a significant other. Are you lonely and wish you had someone in your life? You're not alone! Join our forum and talk to people just like you.

Discussion Object oriented programming

ElTruecel

ElTruecel

NT > EVERYTHING DEATH TO NT PILL DENIERS
★★★★★
Joined
Dec 3, 2022
Posts
17,631
Hello for any Java code cels does anyone have any good videos or good practice so I can truly learn object oriented programming. I want to learn it to the point where I’m sure I’ll get 90-100 if I get tested on it.
 
 
leave this nerdy bullshit
it goes nowhere
all you do is focus on small mistakes that can ruin your whole project
and there is no results that are actually benefical
so much suffering for a little reward
cope being a dev in a large corp is one of the best wagiecagie jobs ever

 
Okay it's simple.

Think you have a class, a basic car, with four wheels

A class extended (call it a Nissan) have all properties of a basic car including four wheels, but you can add your own properties to it that wouldn't affect the main class basic car above. However, when a class is extended from the main class, it is inherited with everything it has.

So

Nissan has four wheels and a spoiler (added)
Toyota has four wheels and a hood scoop
Basic car has four wheels only
 
Another example (may not be correct due to psuedocode)

Main class: bread

class Bread {
String twobreads;
}
class Hamburger extends Bread{
String Ham;
}

Thus the Hamburger class contains both strings, which are twobreads and Ham
 

Thank you for the help. ImmA need at least a 90-100 on the next 2 assessments. I need that B
leave this nerdy bullshit
it goes nowhere
all you do is focus on small mistakes that can ruin your whole project
and there is no results that are actually benefical
so much suffering for a little reward
sadly I can’t drop it. I’m a senior in HS and it’s a stupid AP class I should’ve just taken a normal coding class and not an advanced one FUCK I HATE MYSELF.
Okay it's simple.

Think you have a class, a basic car, with four wheels

A class extended (call it a Nissan) have all properties of a basic car including four wheels, but you can add your own properties to it that wouldn't affect the main class basic car above. However, when a class is extended from the main class, it is inherited with everything it has.

So

Nissan has four wheels and a spoiler (added)
Toyota has four wheels and a hood scoop
Basic car has four wheels only
Alright thank you. So what I understand is

You have an object. An object has its attributes (variables) and its behaviors (methods). You usually do public class (object) then after the bracket put in public object but before that you have to do 2 strings and 1 integer (for example).
 
I'm not sure what you meant by Public class, but there's a main method that you must initialize and it runs once the program is started

public static void main(String[] args) {}​

Thank you for the help. ImmA need at least a 90-100 on the next 2 assessments. I need that B

sadly I can’t drop it. I’m a senior in HS and it’s a stupid AP class I should’ve just taken a normal coding class and not an advanced one FUCK I HATE MYSELF.

Alright thank you. So what I understand is

You have an object. An object has its attributes (variables) and its behaviors (methods). You usually do public class (object) then after the bracket put in public object but before that you have to do 2 strings and 1 integer (for example).
 
C#:
switch(canihavegirlfriend)
{
     case USER_INCEL: return rope(userid);
     case NORMIE: return LDAR(userid);
     case CHAD: return        setAdminPrivileges(userid, TUTORIAL_MODE);
}
 
make sure to know the four pillars of OOP.
 
C#:
switch(canihavegirlfriend)
{
     case USER_INCEL: return rope(userid);
     case NORMIE: return LDAR(userid);
     case CHAD: return        setAdminPrivileges(userid, TUTORIAL_MODE);
}
By the way, cucked C# uses break; on each case, LOL.
 
make sure to know the four pillars of OOP.
which are?
MODEL VIEW CONTROLLER?
NEVER DO MULTI DIMENSIONAL ARRAYS in Pawn because it's unreadable?

enlighten me, brocel. i never dug up myself into reading about OOP, but docs instead.
 
class Foid{
String teehee;
}

class BasedIncel{
void goER();
}
 
which are?
MODEL VIEW CONTROLLER?
NEVER DO MULTI DIMENSIONAL ARRAYS in Pawn because it's unreadable?

enlighten me, brocel. i never dug up myself into reading about OOP, but docs instead.
  • Abstraction.
  • Encapsulation.
  • Inheritance.
  • Polymorphism.

These are very basic concepts that will help you have a good understanding of OOP.
 
  • Abstraction.
  • Encapsulation.
  • Inheritance.
  • Polymorphism.
So basically what I always do, whether it's on a low level language like Pawn or... yikes, webdev with PHP (which I rarely use it anymore because of normie frameworks like Laravel or Yii).
 
class Foid{
String teehee;
}

class BasedIncel{
void goER();
}
public void goER {
if (getincel() != null) {
getgame().setgame(Minecraft);
getincel().setweapon("AK-47");
getincel().setmood("rage");
getincel().setstatus("hERo");
getincel().setplayable(true);
getincel().setplayer(asiacel);
}
}
 
if(incel)
{
//retrieve female id and...
goER(userid, femaleid);
}
public void goER {
if (getincel() != null) {
getgame().setgame(Minecraft);
getincel().setweapon("AK-47");
getincel().setmood("rage");
getincel().setstatus("hERo");
getincel().setplayable(true);
getincel().setplayer(asiacel);
}
}
:feelskek: NICE
 
Hello for any Java code cels does anyone have any good videos or good practice so I can truly learn object oriented programming. I want to learn it to the point where I’m sure I’ll get 90-100 if I get tested on it.
youtube and make ur own projects. make a github for yourself

leave this nerdy bullshit
it goes nowhere
all you do is focus on small mistakes that can ruin your whole project
and there is no results that are actually benefical
so much suffering for a little reward
that's what a debugger is for
 
@AsiaCel @nohope. @war_with_myself @asgard
For homework I did this
public class Name {
private String firstName;
private char middleInitial;
private String lastName;

public Name(String firstName, char middleInitial, String lastName) {
this.firstName = firstName;
this.middleInitial = middleInitial;
this.lastName = lastName;
}
public String getFirstName (){
return firstName;
}
public char getMiddleInitial (){
return middleInitial;
}
public String getLastName (){
return lastName;
}
public void sefirstName(String firstName) {
this.firstName = firstName;
}
public void setmiddleInitial(String middleInitial) {
this.middleInitial = middleInitial;
}
public void lastName(String lastName) {
this.lastName = lastName;
}
}
But it’s telling me this
Error emitted from internal testing code. This error is occurring when our internal testing code is trying to call your code. If you see this, it may mean that you have the wrong header for your solution, or a mismatched { } ( ) brace.
You are referring to a name that is not recognized. Perhaps you misspelled it, mis-capitalized it, or forgot to declare it?
cannot find symbol: method setFirstName(String) in variable name of type Name
name.setFirstName(first);

I also still don’t fully understand methods somehow and I think I need to actually practice but the concept as a whole is hard to understand when methods themselves have different concepts in different areas of Java.
 
@AsiaCel @nohope. @war_with_myself @asgard
For homework I did this
public class Name {
private String firstName;
private char middleInitial;
private String lastName;

public Name(String firstName, char middleInitial, String lastName) {
this.firstName = firstName;
this.middleInitial = middleInitial;
this.lastName = lastName;
}
public String getFirstName (){
return firstName;
}
public char getMiddleInitial (){
return middleInitial;
}
public String getLastName (){
return lastName;
}
public void sefirstName(String firstName) {
this.firstName = firstName;
}
public void setmiddleInitial(String middleInitial) {
this.middleInitial = middleInitial;
}
public void lastName(String lastName) {
this.lastName = lastName;
}
}
But it’s telling me this
Error emitted from internal testing code. This error is occurring when our internal testing code is trying to call your code. If you see this, it may mean that you have the wrong header for your solution, or a mismatched { } ( ) brace.
You are referring to a name that is not recognized. Perhaps you misspelled it, mis-capitalized it, or forgot to declare it?
cannot find symbol: method setFirstName(String) in variable name of type Name
name.setFirstName(first);

I also still don’t fully understand methods somehow and I think I need to actually practice but the concept as a whole is hard to understand when methods themselves have different concepts in different areas of Java.
You mis used string for middle initial

public void setmiddleInitial(String middleInitial) {
this.middleInitial = middleInitial;
}

Change it to char
 
@AsiaCel @nohope. @war_with_myself @asgard
For homework I did this
public class Name {
private String firstName;
private char middleInitial;
private String lastName;

public Name(String firstName, char middleInitial, String lastName) {
this.firstName = firstName;
this.middleInitial = middleInitial;
this.lastName = lastName;
}
public String getFirstName (){
return firstName;
}
public char getMiddleInitial (){
return middleInitial;
}
public String getLastName (){
return lastName;
}
public void sefirstName(String firstName) {
this.firstName = firstName;
}
public void setmiddleInitial(String middleInitial) {
this.middleInitial = middleInitial;
}
public void lastName(String lastName) {
this.lastName = lastName;
}
}
But it’s telling me this
Error emitted from internal testing code. This error is occurring when our internal testing code is trying to call your code. If you see this, it may mean that you have the wrong header for your solution, or a mismatched { } ( ) brace.
You are referring to a name that is not recognized. Perhaps you misspelled it, mis-capitalized it, or forgot to declare it?
cannot find symbol: method setFirstName(String) in variable name of type Name
name.setFirstName(first);

I also still don’t fully understand methods somehow and I think I need to actually practice but the concept as a whole is hard to understand when methods themselves have different concepts in different areas of Java.

String middleInital should be a char not a String

how are u creating the object in your main class
 
@AsiaCel @nohope. It says cannot find symbol char in class name.
 
@AsiaCel @nohope. It says cannot find symbol char in class name.
class Main {
public static void main(String[] args) {
Name n = new Name("fasdf",'f',"fgefas");
n.setfirstName("fg");
n.setmiddleInitial('g');
System.out.println(n.getMiddleInitial());
}
}


that works for me
 
cope being a dev in a large corp is one of the best wagiecagie jobs ever

chad only
 
class Main {
public static void main(String[] args) {
Name n = new Name("fasdf",'f',"fgefas");
n.setfirstName("fg");
n.setmiddleInitial('g');
System.out.println(n.getMiddleInitial());
}
}


that works for me
Alright I’ll check it again. I think PracticeIt is just being a bitch
 

Similar threads

Liu KANG
Replies
13
Views
380
BlueCore
BlueCore
A
Replies
24
Views
497
AntibioticsBro
A
B
Replies
5
Views
211
BlackPillJourney
B
BlackLowLtn
Replies
55
Views
904
BlackLowLtn
BlackLowLtn

Users who are viewing this thread

shape1
shape2
shape3
shape4
shape5
shape6
Back
Top