---
title: "Discussion on \"How to fix Dart Lang Error: RangeError (index): Index out of range: no indices are valid: 0\" | Hashnode"
description: "Discussion on \"How to fix Dart Lang Error: RangeError (index): Index out of range: no indices are valid: 0\". In C-like languages like JS, it's a common operation to assign a value to an array in a for loop at a given index using []. Like this:\n\nWith Dart lang trying this:\n\nYou get the error: RangeError (index): Index out of range: no indices are valid: 0\nTh..."
url: "https://hashnode.com/posts/how-to-fix-dart-lang-error-rangeerror-index-index-out-of-range-no-indices-are-valid-0/646f05d85496eb714b8e6cab"
---

[Feed](https://hashnode.com/feed) /

Discussion

# [How to fix Dart Lang Error: RangeError (index): Index out of range: no indices are valid: 0](https://lkioi.hashnode.dev/how-to-fix-dart-lang-error-rangeerror-index-index-out-of-range-no-indices-are-valid-0?utm_source=hashnode&utm_medium=feed)

In C-like languages like JS, it's a common operation to assign a value to an array in a for loop at a given index using \[\]. Like this: With Dart lang trying this: You get the error: RangeError (index): Index out of range: no indices are valid: 0 Th...

May 25, 2023 · 1 min read · lkioi.hashnode.dev  
Updated Jun 17, 2023  
Read the article

-   [#dart](https://hashnode.com/tag/dart)

## Written by

[Leonard Kioi Kinyanjui](https://hashnode.com/@lkioi)

@lkioi

  
[View profile](https://hashnode.com/@lkioi)

React · NextJS · Typescript

I am a Frontend Software Engineer at Microsoft working on the Search Results Page on office.com and sharepoint.com. Typescript, React, NextJS, and low-code or no-code solutions are my favorite tools.

## Responses

Markdown supported · ⌘↵ to post

No responses yet.
