Coding Interview | Software Engineer (H Tree)

แชร์
ฝัง
  • เผยแพร่เมื่อ 26 ส.ค. 2024

ความคิดเห็น • 4

  • @MrUGOTpwNEDbyme
    @MrUGOTpwNEDbyme 3 ปีที่แล้ว +4

    Lovely! This channel deserves more views! Just hang in till you hit 100k, then the rate of subscribers will increase, it's all snowball effect

  • @emanuels3501
    @emanuels3501 3 ปีที่แล้ว

    The length of the sides of H would be off since you are doing a lot of integer divisions in your code. A correct approach would be to create a private overload of drawHTree that accepts (double x, double y, double length, ...) and delegate the actual drawing there.

    • @oussama40612
      @oussama40612 3 ปีที่แล้ว

      How would you go about passing doubles to the drawline then as this accepts ints only?

    • @emanuels3501
      @emanuels3501 3 ปีที่แล้ว

      @@oussama40612 static cast