# Hack

> programming language

**Wikidata**: [Q15971618](https://www.wikidata.org/wiki/Q15971618)  
**Wikipedia**: [English](https://en.wikipedia.org/wiki/Hack_(programming_language))  
**Source**: https://4ort.xyz/entity/hack

## Summary
Hack is a programming language developed by Meta (formerly Facebook) in 2014, designed for web development with gradual typing, dynamic typing, and weak typing features. It was influenced by PHP and Java, and is part of the HHVM (HipHop Virtual Machine) ecosystem.

## Key Facts
- **Inception**: 2014 (first released in 2014)
- **Developer**: Meta (formerly Facebook)
- **License**: MIT License
- **Typing disciplines**: Gradual typing, dynamic typing, weak typing, static typing, inference typing
- **Influenced by**: PHP, Java, OCaml, and others
- **Website**: [hacklang.org](https://hacklang.org)
- **Source code repository**: [GitHub](https://github.com/facebook/hhvm)
- **Latest version**: 3.14.5 (as of 2016-09-28)
- **Aliases**: ハック
- **Copyright status**: Copyrighted

## FAQs
### Q: What is Hack used for?
A: Hack is primarily used for web development, particularly within the HHVM ecosystem, and is designed to be a modern, type-safe alternative to PHP.

### Q: Who created Hack?
A: Hack was created by Meta (formerly Facebook) and first released in 2014.

### Q: What are the typing features of Hack?
A: Hack supports gradual typing, dynamic typing, weak typing, static typing, and inference typing, making it flexible for different development needs.

### Q: How does Hack differ from PHP?
A: Hack was designed as a successor to PHP, incorporating modern features like gradual typing and better performance through the HHVM runtime.

### Q: Where can I find Hack's source code?
A: The source code for Hack is available on GitHub at [https://github.com/facebook/hhvm](https://github.com/facebook/hhvm).

## Why It Matters
Hack was developed to address the limitations of PHP, particularly in terms of type safety and performance. By introducing gradual typing and integrating with the HHVM runtime, Hack aimed to provide a more robust and efficient language for web development. Its development by Meta (formerly Facebook) positioned it as a key tool in the company's infrastructure, supporting large-scale applications. The language's adoption within Meta's ecosystem highlights its importance in modern web development, where performance and scalability are critical.

## Notable For
- **Gradual typing**: Hack was one of the first widely used languages to implement gradual typing, allowing developers to gradually introduce type annotations.
- **HHVM integration**: Hack is tightly integrated with the HHVM runtime, enabling high performance for web applications.
- **Modern web development**: Hack was designed to be a modern alternative to PHP, incorporating features like type safety and better tooling.
- **Meta's infrastructure**: Hack plays a significant role in Meta's (formerly Facebook's) internal systems, supporting large-scale applications.
- **Open-source**: Hack is open-source under the MIT License, making it accessible to developers worldwide.

## Body
### Overview
Hack is a programming language developed by Meta (formerly Facebook) in 2014. It was created to address the limitations of PHP, particularly in terms of type safety and performance. Hack supports gradual typing, dynamic typing, weak typing, static typing, and inference typing, making it a versatile language for web development.

### Development and Release
- **Inception**: Hack was first released in 2014.
- **Developer**: Meta (formerly Facebook)
- **License**: The language is open-source under the MIT License.
- **Website**: The official website is [hacklang.org](https://hacklang.org).

### Typing Features
Hack's typing system is one of its key features:
- **Gradual typing**: Allows developers to gradually introduce type annotations.
- **Dynamic typing**: Supports dynamic typing for flexibility.
- **Weak typing**: Includes weak typing for compatibility.
- **Static typing**: Offers static typing for type safety.
- **Inference typing**: Uses type inference to reduce boilerplate.

### Influences
Hack was influenced by several programming languages:
- **PHP**: Hack was designed as a successor to PHP.
- **Java**: Influenced Hack's object-oriented features.
- **OCaml**: Influenced Hack's type system.
- **Other languages**: Additional influences include Q2370 and Q34010.

### Versions and Releases
Hack has undergone several releases, with the latest version being 3.14.5 (as of 2016-09-28). Key releases include:
- **2.2.0**: Released on 2016-09-28.
- **3.9.7, 3.9.8, 3.9.9**: Released on 2016-09-28.
- **3.12.6, 3.12.7, 3.12.8**: Released on 2016-09-28.
- **3.14.3, 3.14.4, 3.14.5**: Released on 2016-09-28.

### Source Code and Community
- **Source code repository**: The source code is available on GitHub at [https://github.com/facebook/hhvm](https://github.com/facebook/hhvm).
- **Community engagement**: Hack has a presence on Twitter (@HackLang) and other platforms.

### Wikipedia and Wikidata
- **Wikipedia**: Hack has a Wikipedia page titled "Hack (programming language)".
- **Wikidata**: Hack is described as a programming language on Wikidata.

## Schema Markup
```json
{
  "@context": "https://schema.org",
  "@type": "Thing",
  "name": "Hack",
  "description": "A programming language developed by Meta for web development with gradual typing features.",
  "url": "https://hacklang.org",
  "sameAs": ["https://www.wikidata.org/wiki/Q186055", "https://en.wikipedia.org/wiki/Hack_(programming_language)"],
  "additionalType": "ProgrammingLanguage"
}

## References

1. [Source](https://github.com/facebook/hhvm/blob/master/hphp/hack/LICENSE)
2. [Release 2.2.0. 2016](https://github.com/facebook/hhvm/releases/tag/HHVM-2.2.0)
3. [Release 3.9.7. 2016](https://github.com/facebook/hhvm/releases/tag/HHVM-3.9.7)
4. [Release 3.9.8. 2016](https://github.com/facebook/hhvm/releases/tag/HHVM-3.9.8)
5. [Release 3.9.9. 2016](https://github.com/facebook/hhvm/releases/tag/HHVM-3.9.9)
6. [Release 3.12.6. 2016](https://github.com/facebook/hhvm/releases/tag/HHVM-3.12.6)
7. [Release 3.12.7. 2016](https://github.com/facebook/hhvm/releases/tag/HHVM-3.12.7)
8. [Release 3.12.8. 2016](https://github.com/facebook/hhvm/releases/tag/HHVM-3.12.8)
9. [Release 3.14.3. 2016](https://github.com/facebook/hhvm/releases/tag/HHVM-3.14.3)
10. [Release 3.14.4. 2016](https://github.com/facebook/hhvm/releases/tag/HHVM-3.14.4)
11. [Release 3.14.5. 2016](https://github.com/facebook/hhvm/releases/tag/HHVM-3.14.5)
12. [Release 3.15.0. 2016](https://github.com/facebook/hhvm/releases/tag/HHVM-3.15.0)
13. [Release 4.172. 2022](https://hhvm.com/blog/2022/11/02/hhvm-4.172.html)