Computer Science, asked by simrungta89, 6 months ago

One of the streets in your city has a total of L street lights. Each light i covers the street from
Xi to Yi distance. Find the length of street covered with light.
Input Specification:
input1: L, denoting the number of street lights.
input2: An array of L* 2 elements. For each row i, (Xi, Yi) denote that the
street light i covers the distance from Xi to Yi.
Output Specification:
Your function should return the length of the street covered with light.
Example 1:
input1: 1,
input2: {{5,10 } }
Output: 5​

Answers

Answered by freedarajesh2003
0

Answer:

Explanation:

Each light i covers the street fr… Get the ... Street Lights One of the streets in your city has a total of L street lights. ... Find the length of street covered with light. Input Specification: input1: L, denoting the number of street lights. input2: An array of L* 2 elements. ... street light i covers the distance from Xi to Yi.

Similar questions