# Manhattan Distance

 1: 1: 2: 2:

Output: `Press calculate`

Formula:`d = |x1 - x2| + |y1 - y2|`

## Introduction to Manhattan Distance Calculator

The Manhattan distance, also known as Taxicab distance or L1 Norm, is the sum of the absolute differences of their coordinates. It represents the distance between two points in a grid-based path planning by moving only horizontally and vertically, as opposed to diagonally. This metric imitates the reality of traveling in a city arranged in a grid pattern, similar to Manhattan's layout.

## Parameter usage:

• `x1` = x-coordinate of the first point
• `y1` = y-coordinate of the first point
• `x2` = x-coordinate of the second point
• `y2` = y-coordinate of the second point

## Output:

• `d` = Manhattan distance between two points

## Data validation

The function will return "Please enter valid numerical coordinates" if any of the inputs are non-numeric.

## Summary

This calculator takes into account the coordinates of two points and outputs the Manhattan distance between them, which is practical for determining distance in urban grid-like street layouts.