os.Path.separator

Returns the character used to separate path segments.

Syntax

os.Path.separator()
  RETURNS STRING

Usage

Use this method to build a path from two components.

On UNIX™, the directory separator is '/'.

On Windows®, the directory separator is '\'.