Welcome to the Treehouse Community

Want to collaborate on code errors? Have bugs you need feedback on? Looking for an extra set of eyes on your latest project? Get support with fellow developers, designers, and programmers of all backgrounds and skill levels here with the Treehouse Community! While you're at it, check out some resources Treehouse students have shared here.

Looking to learn something new?

Treehouse offers a seven day free trial for new students. Get access to thousands of hours of content and join thousands of Treehouse students and alumni in the community today.

Start your free trial

Digital Literacy

What exactly is a library in programming?

I have been hearing about libraries when it comes to programming where ever I go but no one has ever given me a definition of what they really are.

1 Answer

Steven Parker
Steven Parker
231,269 Points

A "library" is a collection of program parts that do common and/or specialized things that save the programmer from needing to "reinvent the wheel" when writing software. It usually consists of functions to call and object classes you can instantiate. A common example might be functions that deal with dates and times, and a specialized one could be software for manipulating an smart thermostat (such specialized libraries are typically provided with a device purchase).

By using libraries, the programmer can concentrate on the unique aspects of the application being developed.