Skip to content

Subtraction in PowerShell results in strange result value #15789

@daxian-dbw

Description

@daxian-dbw

Prerequisites

Steps to reproduce

11111.11 - 11110.01 or 11111.11 - 11110

Expected behavior

PS> 11111.11 - 11110.01
1.1

PS> 11111.11 - 11110
1.11

Actual behavior

PS> 11111.11 - 11110.01
1.10000000000036

PS> 11111.11 - 11110
1.11000000000058

Error details

N/A

Environment data

Name                           Value
----                           -----
PSVersion                      7.2.0-preview.6
PSEdition                      Core
GitCommitId                    7.2.0-preview.6
OS                             Microsoft Windows 10.0.19043
Platform                       Win32NT
PSCompatibleVersions           {1.0, 2.0, 3.0, 4.0…}
PSRemotingProtocolVersion      2.3
SerializationVersion           1.1.0.1
WSManStackVersion              3.0

Visuals

N/A

Metadata

Metadata

Assignees

No one assigned

    Labels

    Needs-TriageThe issue is new and needs to be triaged by a work group.Resolution-No ActivityIssue has had no activity for 6 months or moreWG-Engine-Format

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions