Top 1K Features Creators Events Podcasts Books Extensions Interviews Blog Explorer CSV

Mojo

< >

Mojo is an open source programming language created in 2022 by Chris Lattner.

#115on PLDB 2Years Old
Download source code:
git clone https://github.com/modularml/mojo
Homepage · REPL · Source Code · Release Notes · Docs

Mojo combines the usability of Python with the performance of C, unlocking unparalleled programmability of AI hardware and extensibility of AI models.


Example from the web:
def softmax(lst): norm = np.exp(lst - np.max(lst)) return norm / norm.sum() struct NDArray: def max(self) -> NDArray: return self.pmap(SIMD.max) struct SIMD[type: DType, width: Int]: def max(self, rhs: Self) -> Self: return (self >= rhs).select(self, rhs)

Language features

Feature Supported Example Token
hasGradualTypes ✓ v: ArraySlice[Int]

- Build the next great programming language · Add · About · Search · Keywords · Livestreams · Labs · Resources · Acknowledgements

Built with Scroll v144.0.0