🤑 Join the Treehouse affiliate program and earn 25% recurring commission!

New No-Code Track! 🚀start learning today!

🌟 Dreaming of a bright future? 🎓 Ask about the Treehouse Scholarship program! 🚀

✨ Earn college credits in Cybersecurity, JS, HTML, CSS and Python

  • Treehouse Logo
  • Plans
    Chevron
    • For Individuals
    • For Businesses
    • For Schools
    • For Libraries
    • For Military
  • Library
    Chevron
    • All Courses
    • Tracks
    • College Credit
  • Techdegree
    Chevron
    • Overview
    • Front End Development
    • Full Stack JavaScript
    • Data Analysis
    • UX Design
    • Python
  • Community
    Chevron
    • Code Adventures
    • Discord
    • Forum
    • Success Stories
    • Treehouse Links
    • 100 Days of Code
  • Resources
    Chevron
    • Career Toolbox
    • CodeForward
    • Free Treehouse Near Me
    • Jobs
    • Blog
    • Support
    • About
  • For Individuals For Businesses For Schools For Libraries For Military
  • All Courses Tracks College Credit
  • Overview Front End Web Development Full Stack JavaScript Python Development Data Analysis UX Design
  • Code Adventures Discord Forum Success Stories Treehouse Links 100 Days of Code
  • Career Toolbox CodeForward Free Treehouse Near Me Jobs Blog Support About
  • Sign In
  • Free Trial
Instagram Twitter Facebook YouTube LinkedIn
    • Newest
      • Newest
      • Active
      • Unanswered
      • Featured
    • All Topics
      • All Topics
      • • General Discussion
      • • AI
      • • Android
      • • APIs
      • • Coding for Kids
      • • College Credit
      • • Computer Science
      • • CSS
      • • Data Analysis
      • • Databases
      • • Design
      • • Development Tools
      • • Digital Literacy
      • • Game Development
      • • Go Language
      • • HTML
      • • Java
      • • JavaScript
      • • Learning Resources
      • • Machine Learning
      • • No-Code
      • • PHP
      • • Professional Growth
      • • Python
      • • Quality Assurance
      • • React
      • • Ruby
      • • Security
      • • Swift
  • k doshi
    k doshi
    128 Points

    Can anyone explain? How did Craig use it to explain in the video?

    Posted February 17, 2019 1:08pm by k doshi
    k doshi
    128 Points
    • Java
    • Java Data Structures
    • Exploring the Java Collection Framework
    • Lists

    1 Answer

  • Andre Kucharzyk
    Andre Kucharzyk
    4,479 Points

    4:54 Why we use Collection.sort(fruit) instead of....

    Posted February 28, 2018 8:45pm by Andre Kucharzyk
    Andre Kucharzyk
    4,479 Points
    • Java
    • Java Data Structures - Retired
    • Exploring the Java Collection Framework
    • Lists

    2 Answers

  • Andre Kucharzyk
    Andre Kucharzyk
    4,479 Points

    Jshell in InteliJ. Code ain't running

    Posted February 28, 2018 8:06pm by Andre Kucharzyk
    Andre Kucharzyk
    4,479 Points
    • Java
    • Java Data Structures - Retired
    • Exploring the Java Collection Framework
    • Lists

    4 Answers

  • Kayla Flynn
    Kayla Flynn
    7,652 Points

    Why doesn't the code run correctly when there are commented lines throughout the code using "//"?

    Posted July 6, 2017 2:09pm by Kayla Flynn
    Kayla Flynn
    7,652 Points
    • Java
    • Java Data Structures
    • Exploring the Java Collection Framework
    • Lists

    2 Answers

  • Ian Taylor
    PLUS
    Ian Taylor
    Courses Plus Student 1,420 Points

    Why do I get an error in Eclipse with this code?

    Posted June 14, 2017 10:17am by Ian Taylor
    Ian Taylor
    Courses Plus Student 1,420 Points
    • Java
    • Java Data Structures - Retired
    • Exploring the Java Collection Framework
    • Lists

    1 Answer

  • Dave Jindal
    Dave Jindal
    4,000 Points

    What happens when you use the remove(int indexordata) method, in a List<int> ?

    Posted April 23, 2017 11:30pm by Dave Jindal
    Dave Jindal
    4,000 Points
    • Java
    • Java Data Structures
    • Exploring the Java Collection Framework
    • Lists

    2 Answers

  • Awais Jamil
    Awais Jamil
    7,539 Points

    didn't understood why Craig used List<String> on the decleration and new ArrayList<String> on the Right ?

    Posted January 30, 2017 3:21pm by Awais Jamil
    Awais Jamil
    7,539 Points
    • Java
    • Java Data Structures - Retired
    • Exploring the Java Collection Framework
    • Lists

    1 Answer

  • Christopher Mlalazi
    seal-mask
    .a{fill-rule:evenodd;}techdegree seal-36
    Christopher Mlalazi
    Front End Web Development Techdegree Graduate 17,305 Points

    Error

    Posted January 19, 2017 9:17pm by Christopher Mlalazi
    .a{fill-rule:evenodd;}techdegree seal-36
    Christopher Mlalazi
    Front End Web Development Techdegree Graduate 17,305 Points
    • Java
    • Java Data Structures
    • Exploring the Java Collection Framework
    • Lists

    1 Answer

  • zombiemk7
    zombiemk7
    1,076 Points

    What is this happening ?

    Posted December 19, 2016 1:47pm by zombiemk7
    zombiemk7
    1,076 Points
    • Java
    • Java Data Structures
    • Exploring the Java Collection Framework
    • Lists

    1 Answer

  • Matthew Francis
    Matthew Francis
    6,967 Points

    Difference between Array.asList(...) and a normal array? they both return a fixed size of arrays

    Posted August 9, 2016 6:34am by Matthew Francis
    Matthew Francis
    6,967 Points
    • Java
    • Java Data Structures
    • Exploring the Java Collection Framework
    • Lists

    1 Answer

  • Matthew Francis
    Matthew Francis
    6,967 Points

    What does the number in fruit.toArray[0] represent?

    Posted August 8, 2016 3:27pm by Matthew Francis
    Matthew Francis
    6,967 Points
    • Java
    • Java Data Structures
    • Exploring the Java Collection Framework
    • Lists

    1 Answer

  • John Fowler
    John Fowler
    7,913 Points

    array list methods

    Posted July 14, 2016 7:08pm by John Fowler
    John Fowler
    7,913 Points
    • Java
    • Java Data Structures
    • Exploring the Java Collection Framework
    • Lists

    2 Answers

  • hbdc
    hbdc
    13,725 Points

    What's the difference between declaring the list as List<String> newList and ArrayList<String> newList = ...?

    Posted July 3, 2016 4:31pm by hbdc
    hbdc
    13,725 Points
    • Java
    • Java Data Structures
    • Exploring the Java Collection Framework
    • Lists

    1 Answer

  • Arnold Rosario
    Arnold Rosario
    16,357 Points

    How come fruit.toArray(new String[0]); creates a new filled array of 3 elements?

    Posted January 12, 2016 5:49pm by Arnold Rosario
    Arnold Rosario
    16,357 Points
    • Java
    • Java Data Structures - Retired
    • Exploring the Java Collection Framework
    • Lists

    1 Answer

  • Arnold Rosario
    Arnold Rosario
    16,357 Points

    What's an example of changing the implementation whenever we want?

    Posted January 12, 2016 5:06pm by Arnold Rosario
    Arnold Rosario
    16,357 Points
    • Java
    • Java Data Structures - Retired
    • Exploring the Java Collection Framework
    • Lists

    1 Answer

  • Dylan Carter
    Dylan Carter
    4,780 Points

    Why would you ever use arrays?

    Posted January 6, 2016 10:25am by Dylan Carter
    Dylan Carter
    4,780 Points
    • Java
    • Java Data Structures
    • Exploring the Java Collection Framework
    • Lists

    3 Answers

  • Eric Chan
    Eric Chan
    4,254 Points

    List myList = new ArrayList<String>(); Can anyone explain this in plain English?

    Posted December 22, 2015 7:07am by Eric Chan
    Eric Chan
    4,254 Points
    • Java
    • Java Data Structures
    • Exploring the Java Collection Framework
    • Lists

    2 Answers

  • Kevin Frostad
    Kevin Frostad
    3,483 Points

    Why do we need to specify the type of the class when making an object of ArrayList?

    Posted December 13, 2015 3:59pm by Kevin Frostad
    Kevin Frostad
    3,483 Points
    • Java
    • Java Data Structures
    • Exploring the Java Collection Framework
    • Lists

    1 Answer

  • Yong Li Soh
    PLUS
    Yong Li Soh
    Courses Plus Student 2,555 Points

    When to Import Interface, implement or do both?

    Posted August 22, 2015 1:50am by Yong Li Soh
    Yong Li Soh
    Courses Plus Student 2,555 Points
    • Java
    • Java Data Structures
    • Exploring the Java Collection Framework
    • Lists

    1 Answer

  • Sina Maleki
    Sina Maleki
    6,135 Points

    Big O Notation problem

    Posted August 1, 2015 11:11am by Sina Maleki
    Sina Maleki
    6,135 Points
    • Java
    • Java Data Structures
    • Exploring the Java Collection Framework
    • Lists

    1 Answer

  • Sina Maleki
    Sina Maleki
    6,135 Points

    Problem

    Posted August 1, 2015 10:07am by Sina Maleki
    Sina Maleki
    6,135 Points
    • Java
    • Java Data Structures
    • Exploring the Java Collection Framework
    • Lists

    3 Answers

  • David Axelrod
    David Axelrod
    36,073 Points

    The reason why we swap data over to lists is so that it can be manipulated easier?

    Posted June 10, 2015 5:47pm by David Axelrod
    David Axelrod
    36,073 Points
    • Java
    • Java Data Structures - Retired
    • Exploring the Java Collection Framework
    • Lists

    1 Answer

  • amathiaitishar
    amathiaitishar
    13,229 Points

    Remark on the methodology of the tutorials...

    Posted June 1, 2015 4:38pm by amathiaitishar
    amathiaitishar
    13,229 Points
    • Java
    • Java Data Structures
    • Exploring the Java Collection Framework
    • Lists

    2 Answers

  • Adiv Abramson
    Adiv Abramson
    6,919 Points

    Why must documentation be inscrutable? What benefit accrues from obtuse, dense and jargon laden text?

    Posted May 13, 2015 3:34am by Adiv Abramson
    Adiv Abramson
    6,919 Points
    • Java
    • Java Data Structures
    • Exploring the Java Collection Framework
    • Lists

    2 Answers

  • Greg Kitchin
    Greg Kitchin
    31,522 Points

    Any reason to use arrays over lists?

    Posted April 20, 2015 9:19pm by Greg Kitchin
    Greg Kitchin
    31,522 Points
    • Java
    • Java Data Structures
    • Exploring the Java Collection Framework
    • Lists

    3 Answers

  • Miguel Gonzalez Rocha
    Miguel Gonzalez Rocha
    2,849 Points

    What are interfaces and superinterfaces?

    Posted March 26, 2015 8:42pm by Miguel Gonzalez Rocha
    Miguel Gonzalez Rocha
    2,849 Points
    • Java
    • Java Data Structures - Retired
    • Exploring the Java Collection Framework
    • Lists

    1 Answer

Posting to the forum is only allowed for members with active accounts.
Please sign in or sign up to post.

    Treehouse

  • About
  • Blog
  • Careers
  • Community
  • Stories
  • Shop
  • Contact
  • Gift Card

See Full Catalogue

Techdegree

  • Front End Web Development
  • Full Stack JavaScript
  • Python Development
  • Data Analysis
  • UX Design

Tracks

  • Learn to Code for Beginners
  • Beginning Python
  • Beginning SQL
  • Beginning Java
  • ...see more

Courses

  • JavaScript Basics
  • Intro to HTML & CSS
  • Python Basics
  • CSS Layout
  • ...see more

Explore

  • Plans
  • Affiliates
  • Perks
  • Free Treehouse Near Me
  • Treehouse for Libraries
  • Treehouse for Businesses
  • Twitter
  • YouTube
  • Facebook
  • LinkedIn
  • Instagram
Terms & Conditions | Privacy

© 2025 Treehouse Island, Inc.