SoftwareSiege's profile picture. 🛡️ Defender of clean code

CodeBarbarian

@SoftwareSiege

🛡️ Defender of clean code

#Java's greatest parlor trick: The blueprint for the universe is also one of the bricks


CodeBarbarian memposting ulang

Every propositional formula can be transformed into conjunctive normal form and into disjunctive normal form.


CodeBarbarian memposting ulang

Jack Kilby developed the integrated circuit in 1958.


🤔 Oh Really? Does #microservices always mean better scalability?

SoftwareSiege's tweet image. 🤔 Oh Really? Does #microservices always mean better scalability?

Answer: 0 Why?: - Parent constructor runs first → calls show() - show() is overridden in Child, so Child. show() is invoked - At this point, Child.value is still default-initialized to 0 The field value = 99 hasn’t been assigned yet - So System.out.println(value) prints 0…

What will be the output of the following #Java code?

SoftwareSiege's tweet image. What will be the output of the following #Java code?


TimSort is #Java’s default sorting algorithm used in Arrays.sort() for objects and Collections.sort(). - It’s a hybrid of Merge Sort and Insertion Sort, designed to perform exceptionally well on real-world data that often contains ordered sequences. - It works by identifying…


What will be the output of the following #Java code?

SoftwareSiege's tweet image. What will be the output of the following #Java code?

Answer: true Why?: - In #Java, Generics enforce type constraints only at compile time - At runtime, type erasure removes generic type parameters - Both List<String> and List<Integer> become raw ArrayList - getClass() reflects the runtime type, not the generic type - So both…

What will be the output of the following #Java code? List<String> strings = new ArrayList<>(); List<Integer> integers = new ArrayList<>(); System.out.println(strings.getClass() == integers.getClass());

true %0
false %100

2 suara · Hasil akhir



United States Tren

Loading...

Something went wrong.


Something went wrong.