JavaRush
AI Academy
new
Promotion
Learning
Courses
Tasks
Quizzes
Games
Help
Schedule of nudges
Internship
Community
Users
Forum
Chat
Articles
Activities
Reviews
Subscriptions
Light theme

Lectures

  • Reviews
  • About us
  • CS50
Start
Start learning
Start learning
  • My progress
  • Courses
  • Quest map
  • Lectures
  • os.Stat, FileInfo, and basic metadata

    Go SELF
    41 level,0 lecture
    We break down how to get a file or directory “passport” via os.Stat: what the os.FileInfo interface is, how to read basic metadata ( Name(), IsDir(), Size(), ModTime(), Mode()), how to handle file system errors via os.IsNotExist/ os.IsPermission, and how to apply this in practice (the inspect utility, checking storage in TaskBox, checking a “regular file” via IsRegular()).
    Open
  • os.ReadDir — listing a directory via DirEntry

    Go SELF
    41 level,1 lecture
    We break down how to get a directory’s contents in Go with a single call using os.ReadDir, what exactly is inside []os.DirEntry, how the “lightweight” DirEntry differs from the full FileInfo, why e.Name() is not a path, how to build a path correctly with filepath.Join, and how to handle errors cleanly ( if err != nil, wrapping with fmt.Errorf using %w).
    Open
  • filepath.WalkDir: recursive traversal and safety

    Go SELF
    41 level,2 lecture
    We break down how to traverse a file tree correctly in Go using filepath.WalkDir: how the fs.WalkDirFunc callback is structured, why it is important to check err, how to control traversal with filepath.SkipDir and SkipAll, and which practical measures help make directory scanning predictable and safe (including lexical validation of a user-supplied path using filepath.IsLocal).
    Open
  • Filtering and sorting traversal results

    Go SELF
    41 level,3 lecture
    We break down a practical pipeline “traverse → collect → filter → sort”: collect WalkDir results into []Item, write predicates based on strings.HasPrefix/ HasSuffix/ Contains, compose conditions via the Filter function, and then make output deterministic using sort.Slice and sort.SliceStable, including a tie-breaker (for example, by path).
    Open
  • File system traversal error strategy

    Go SELF
    41 level,4 lecture
    We break down how to design error handling when recursively walking a file tree in Go using filepath.WalkDir: what the err parameter in the callback means, when to return a regular error and when to use filepath.SkipDir, how to collect “as much data as possible” and still not lose problems with errors.Join, and why wrapping via %w makes diagnostics and error classification (via errors.Is/ errors.As) genuinely convenient.
    Open
Learn
  • Registration
  • Java course
  • Help with tasks
  • Pricing
Community
  • Users
  • Articles
  • Forum
  • Chat
  • Activities
Company
  • About us
  • Contacts
  • Reviews
  • FAQ
  • Support
JavaRushJavaRush — is an interactive online course for learning Java programming from scratch. It contains 1200 practical tasks with one-click solution checking, the necessary minimum of theory on Java basics, and motivating features that help you complete the course: games, quizzes, interesting projects and articles on effective learning and the career of a Java developer.
Follow us
Язык интерфейса
Русский
English
Українська
"Programmers are not born" © 2026 JavaRush
MastercardVisa
"Programmers are not born" © 2026 JavaRush