• Log InLog In
  • Register
Liquid`
Team Liquid Liquipedia
EDT 01:38
CEST 07:38
KST 14:38
  • Home
  • Forum
  • Calendar
  • Streams
  • Liquipedia
  • Features
  • Store
  • EPT
  • TL+
  • StarCraft 2
  • Brood War
  • Smash
  • Heroes
  • Counter-Strike
  • Overwatch
  • Liquibet
  • Fantasy StarCraft
  • TLPD
  • StarCraft 2
  • Brood War
  • Blogs
Forum Sidebar
Events/Features
News
Featured News
[ASL22] Ro24 Preview: Siren's Call7[ASL22] Ro24 Preview: Summer's End9Serral wins HomeStory Cup 2915Serral wins Maestros of the Game 244ByuL, and the Limitations of Standard Play3
Community News
New 3v3 BGH Ladder (and more) on ShieldBattery!16Weekly Cups (August 17-23): Zerg dominate the week0Weekly Cups (August 10-16): SHIN doubles2GSTL Returns in 2026!45Weekly Cups (Aug 3-9): Protoss get shut out7
StarCraft 2
General
SC4ALL II: SC2 Player Announcement 6/8 - Maru PhD study /w SC2 - help with a survey! How would you feel about frequent/monthly balance patches for SC2? Weekly Cups (August 17-23): Zerg dominate the week Geoff 'iNcontroL' Robinson has passed away
Tourneys
PIG STY FESTIVAL 8.0! (13 - 23 August) Sparkling Tuna Cup - Weekly Open Tournament WORTEX 2026 - Hungarian SC2 Finals Budapest SC2 AI Tournament 2026 Fall 2026 GSTL Announcement
Strategy
[G] Having the right mentality to improve
Custom Maps
Nexus Wars 2021 GUIDE [M] (2) Industrial Park
External Content
Mutation # 540 Dodge This The PondCast: SC2 News & Results Mutation # 539 Thunder Dome Mutation # 538 Media Blackout
Brood War
General
New 3v3 BGH Ladder (and more) on ShieldBattery! BGH Auto Balance -> http://bghmmr.eu/ [ASL22] Ro24 Preview: Siren's Call BW General Discussion Pros React To: First 'Fastest' Map in ASL History
Tourneys
[ASL22] Ro24 Group E [ASL22] Ro24 Group D Toronto invitational lan 22 august [Megathread] Daily Proleagues
Strategy
Replay Review Process - What do you do? Odyssey Mineral Stack Saturation Fighting Spirit mining rates Any training maps people recommend?
Other Games
General Games
General RTS Discussion Thread Nintendo Switch Thread Anyone here play Quakeworld back in the day? Stormgate/Frost Giant Megathread EVE Corporation
Dota 2
Official 'what is Dota anymore' discussion
League of Legends
[TL LoL EUW IHs] Teemo shall perish TSM pausing esports and CLG Dead
Heroes of the Storm
Heroes of the Storm 2.0
Hearthstone
Deck construction bug
TL Mafia
TL Mafia Power Rank TL Mafia Community Thread NeO.D_StephenKing vs This Guy From 1 Million Dance
Community
General
Russo-Ukrainian War Thread US Politics Mega-thread Dating: How's your luck? Canadian Politics Mega-thread Artificial Intelligence Thread
Fan Clubs
The Creator Fan Club MarineLorD Fan Club The ShoWTimE Fan Club
Media & Entertainment
Movie Discussion! Anime Discussion Thread
Sports
Football (Soccer) Thread TeamLiquid Health and Fitness Initiative For 2023 MLB/Baseball 2023 NBA General Discussion
World Cup 2022
Tech Support
Computer Build, Upgrade & Buying Resource Thread Simple Questions Simple Answers FPS when play League Of Legend on laptop
TL Community
The Automated Ban List Northern Ireland Global Starcraft
Blogs
Young Players Exit Esports E…
TrAiDoS
LOCKPICKING NOOB
LUCKY_NOOB
Cathedral Of CS And NY pizza a…
FuDDx
Please support my new stand…
Peanutsc
Hello guys!
LIN1s
Customize Sidebar...

Website Feedback

Closed Threads



Active: 4114 users

Official 'what is Dota anymore' discussion - Page 10042

Forum Index > Dota 2 General
Post a Reply
Prev 1 10040 10041 10042 10043 10044 10601 Next
PoulsenB
Profile Joined June 2011
Poland7754 Posts
May 11 2019 17:56 GMT
#200821
Gotta say, I haven't been so invested in a dota tournament in quite some time. I actually watched series other than those with EG.
IdrA fan forever <3 || the clueless one || Marci must be protected at all costs
Firebolt145
Profile Blog Joined May 2010
Lalalaland34505 Posts
May 11 2019 18:47 GMT
#200822
Me too actually, maybe because Liquid is actually doing decent? Or to start getting ready to go to ESL Birmingham whooo
Moderator
PoulsenB
Profile Joined June 2011
Poland7754 Posts
May 11 2019 19:03 GMT
#200823
what's with EG and cliffs hahaha
IdrA fan forever <3 || the clueless one || Marci must be protected at all costs
Faruko
Profile Joined April 2013
Chile34173 Posts
Last Edited: 2019-05-11 22:38:01
May 11 2019 22:29 GMT
#200824
I'm selling my tower pc, the buyer is a Peruvian dude, i told him he can try the pc and started playing a dota 2 match

Damn the guy is fucking good, wtf.

Edit: He fed
Ross was right // "Jesus Christ nahaz is doing shots before my eyes" (Sn0_Man, 2018)
teddyoojo
Profile Blog Joined June 2011
Germany22369 Posts
Last Edited: 2019-05-11 23:07:02
May 11 2019 23:02 GMT
#200825
ok im very confused, is there a way to compare 2 obj with the contains method in java using this hashcode method

+ Show Spoiler +
public class Thing{

public int hashCode(){
return name.hashCode();
}

like whats the best way for this method, which is supposed to check if parameter Thing is in the arraylist, to look?
public boolean isInTheBox(Thing thing){}



(no idea if that is understandable in any way)
Esports historian since 2000. Creator of 'The Universe' and 'The best scrambled Eggs 2013'. Host of 'Star Wars Marathon 2015'. Thinker of 'teddyoojo's Thoughts'. Earths and Moons leading CS:GO expert. Lord of the Rings.
Nevuk
Profile Blog Joined March 2009
United States16280 Posts
May 11 2019 23:28 GMT
#200826
Wouldn't you return "this.hashcode"?
Easiest way to check if something is in an arraylist is the arraylist.contains(thing) method, with streams as the second easiest. What does "best" mean here? Fastest, fewest lines?
teddyoojo
Profile Blog Joined June 2011
Germany22369 Posts
Last Edited: 2019-05-11 23:51:44
May 11 2019 23:45 GMT
#200827
yes but it literally wont work arraylist.contains(thing) it just gives out false instead of true when it should return true T_T

if i return this.hashcode() then theres no point overwriting the hashcode method also it should compare only based on the name therefore the overwriting hashcode method

its hard to explain without showing the relevant parts IDK
Esports historian since 2000. Creator of 'The Universe' and 'The best scrambled Eggs 2013'. Host of 'Star Wars Marathon 2015'. Thinker of 'teddyoojo's Thoughts'. Earths and Moons leading CS:GO expert. Lord of the Rings.
Nevuk
Profile Blog Joined March 2009
United States16280 Posts
Last Edited: 2019-05-11 23:56:47
May 11 2019 23:55 GMT
#200828
This is the easiest:
CurrentAccount conta5 = new CurrentAccount("João Lopes", 3135);
boolean itemExists = lista.stream().anyMatch(c -> c.equals(conta5))

https://stackoverflow.com/questions/4404084/check-if-a-value-exists-in-arraylist

If you can't use java 8 then yeah, you have to overload hashcode and equals methods. Very common task though, lots of examples.
teddyoojo
Profile Blog Joined June 2011
Germany22369 Posts
May 11 2019 23:58 GMT
#200829
well i understand that method but i just want to know why my arraylist.contains(obj) WONT RETURN TRUE T_T_T_T_T_T_T_T_T_
Esports historian since 2000. Creator of 'The Universe' and 'The best scrambled Eggs 2013'. Host of 'Star Wars Marathon 2015'. Thinker of 'teddyoojo's Thoughts'. Earths and Moons leading CS:GO expert. Lord of the Rings.
Nevuk
Profile Blog Joined March 2009
United States16280 Posts
Last Edited: 2019-05-12 00:22:27
May 12 2019 00:09 GMT
#200830
On May 12 2019 08:58 teddyoojo wrote:
well i understand that method but i just want to know why my arraylist.contains(obj) WONT RETURN TRUE T_T_T_T_T_T_T_T_T_

It is because it uses the .equals method underneath the code. This works really well for int and strings, but not for user defined objects.

See here : https://www.geeksforgeeks.org/difference-equals-method-java

Edit:
Basically it is comparing their location in memory rather than their value if it using the default .equals method.
teddyoojo
Profile Blog Joined June 2011
Germany22369 Posts
May 12 2019 00:27 GMT
#200831
but i overloaded the equals method aswell to only take name into consideration
Esports historian since 2000. Creator of 'The Universe' and 'The best scrambled Eggs 2013'. Host of 'Star Wars Marathon 2015'. Thinker of 'teddyoojo's Thoughts'. Earths and Moons leading CS:GO expert. Lord of the Rings.
Nevuk
Profile Blog Joined March 2009
United States16280 Posts
Last Edited: 2019-05-12 01:14:57
May 12 2019 01:04 GMT
#200832
On May 12 2019 09:27 teddyoojo wrote:
but i overloaded the equals method aswell to only take name into consideration

How did you overload it? You would need to override the equals method with the @Override command. In the post earlier you only had the hashcode method. Overriding the hashcode is only a small performance boost after you've overridden the equals method (so there's no reason to ever do it on a modern computer). Well, or if you are using hash lists like hashmap or hashsets.


Your hashcode has to return an int. You can't just do it on the name string, as it can return different values. There are a lot of ways to override it, but usually it involves creating an int as part of the object definition and using this to generate the hashcode.
teddyoojo
Profile Blog Joined June 2011
Germany22369 Posts
May 12 2019 01:14 GMT
#200833
oh my i just noticed that the equals method doesnt override why doesnt it override ???
Esports historian since 2000. Creator of 'The Universe' and 'The best scrambled Eggs 2013'. Host of 'Star Wars Marathon 2015'. Thinker of 'teddyoojo's Thoughts'. Earths and Moons leading CS:GO expert. Lord of the Rings.
Nevuk
Profile Blog Joined March 2009
United States16280 Posts
May 12 2019 01:16 GMT
#200834
On May 12 2019 10:14 teddyoojo wrote:
oh my i just noticed that the equals method doesnt override why doesnt it override ???

At least on eclipse you just have to add @Override before the class definition.

Like this:
@Override
public boolean equals(Object object)
{
boolean sameSame = false;

if (object != null && object instanceof Thing)
{
sameSame = this.value == ((Thing) object).value;
}

return sameSame;
}
teddyoojo
Profile Blog Joined June 2011
Germany22369 Posts
May 12 2019 01:20 GMT
#200835
it just wont let me T_T and normally intellij would @override itself when applicable
Esports historian since 2000. Creator of 'The Universe' and 'The best scrambled Eggs 2013'. Host of 'Star Wars Marathon 2015'. Thinker of 'teddyoojo's Thoughts'. Earths and Moons leading CS:GO expert. Lord of the Rings.
Nevuk
Profile Blog Joined March 2009
United States16280 Posts
May 12 2019 01:23 GMT
#200836
I can only use eclipse at work, but I do think intellij is much better. On eclipse if that happened I would do a clean and rebuild of the project. Alternative is that you don't have the class file setup as a valid object (ie, you are missing a constructor)
teddyoojo
Profile Blog Joined June 2011
Germany22369 Posts
Last Edited: 2019-05-12 01:31:55
May 12 2019 01:26 GMT
#200837
watever its 3.30 and i give up
thanks tho nevuk
Esports historian since 2000. Creator of 'The Universe' and 'The best scrambled Eggs 2013'. Host of 'Star Wars Marathon 2015'. Thinker of 'teddyoojo's Thoughts'. Earths and Moons leading CS:GO expert. Lord of the Rings.
rabidch
Profile Joined January 2010
United States20289 Posts
May 12 2019 04:02 GMT
#200838
one solution is to not use java
LiquidDota StaffOnly a true king can play the King.
Artisreal
Profile Joined June 2009
Germany9235 Posts
May 12 2019 07:57 GMT
#200839
Wohoo liquid! What a day of dota! Fingers crossed that the finals day will be much like yesterday.

Watched most of it while doing housework and two of the last 3 games on my newly wall mounted monitor in my comfy chair with a beer. That was great!

Let's go liquid! Secret seems too strong though!
passive quaranstream fan
PoulsenB
Profile Joined June 2011
Poland7754 Posts
May 12 2019 08:55 GMT
#200840
This Major has been great so far, has that feel of a "mini TI" to it.
IdrA fan forever <3 || the clueless one || Marci must be protected at all costs
Prev 1 10040 10041 10042 10043 10044 10601 Next
Please log in or register to reply.
Live Events Refresh
Next event in 4h 23m
[ Submit Event ]
Live Streams
Refresh
StarCraft 2
Nina 102
StarCraft: Brood War
Rain 2824
GuemChi 1563
Mong 182
Bale 22
Icarus 7
League of Legends
JimRising 758
Counter-Strike
Coldzera 1314
Super Smash Bros
Mew2King169
Other Games
WinterStarcraft468
C9.Mang0358
NeuroSwarm129
RuFF_SC2122
[ Show 17 non-featured ]
StarCraft 2
• Berry_CruncH292
• practicex 23
• IndyKCrew
• Migwel
• AfreecaTV YouTube
• intothetv
• Kozan
StarCraft: Brood War
• Azhi_Dahaki23
• Light_VIP 14
• ZZZeroYoutube
• STPLYoutube
• BSLYoutube
Dota 2
• masondota21178
• lizZardDota2149
League of Legends
• Rush1249
• Lourlo1159
• Stunt378
Upcoming Events
Afreeca Starleague
4h 23m
Soulkey vs PianO
JyJ vs sSak
GSL
5h 23m
PiGosaur Cup
18h 23m
Afreeca Starleague
1d 4h
Mini vs Calm
Queen vs EffOrt
Replay Cast
1d 18h
The PondCast
2 days
Replay Cast
2 days
Escore
3 days
IntoTheTV X SOOP
3 days
Korean StarCraft League
3 days
[ Show More ]
GSL
4 days
Replay Cast
4 days
Sparkling Tuna Cup
5 days
WardiTV Weekly
5 days
Liquipedia Results

Completed

Proleague 2026-08-24
PiG Sty Festival 8.0
META DYMY #4

Ongoing

KCM Race Survival 2026 Season 3
K-JUNGMAN
ASL Season 22
Super Anchor Qualifying S3
CSL Season 22: Qualifier 1
CSL Season 22: Qualifier 2
RSL Revival: Season 6
Light Tournament 2026
Esports World Cup 2026
Esports World Cup 2026: LCQ
BLAST Bounty Summer 2026
BLAST Bounty Summer Qual
Stake Ranked Episode 3
XSE Pro League 2026
IEM Cologne Major 2026

Upcoming

BSL 2026 LAN: Kraków
CSL 2026 AUTUMN (S22)
Acropolis #5
Acropolis #5 - TRS
Blizzard Classic Cup 2026
Acropolis #5 - GSA
Acropolis #5 - GSB
HSC XXX
SC4ALL II: StarCraft II
Kung Fu Cup 2026 Grand Finals
RSL Offline Finals
Calamity Invitational
Big Dog Cup 2026 Div 1
IEM Beijing 2026
Stake Ranked Episode 5
PGL Masters Bucharest 2026
Thunderpick World Champ. '26
ESL Pro League Season 24
Stake Ranked Episode 4
1win Private Club #1
Logitech G Play Connect 2026
SL StarSeries Fall 2026
FISSURE Playground #3
BLAST Open Fall 2026
TLPD

1. ByuN
2. TY
3. Dark
4. Solar
5. Stats
6. Nerchio
7. sOs
8. soO
9. INnoVation
10. Elazer
1. Rain
2. Flash
3. EffOrt
4. Last
5. Bisu
6. Soulkey
7. Mini
8. Sharp
Sidebar Settings...

Advertising | Privacy Policy | Terms Of Use | Contact Us

Original banner artwork: Jim Warren
The contents of this webpage are copyright © 2026 TLnet. All Rights Reserved.