Question: During summers BESCOM switches to the optimal power consumption technique wherein the transmission lines are placed at different locations in Bangalore. The power is
During summers BESCOM switches to the optimal power consumption technique wherein the transmission lines are placed at different locations in Bangalore. The power is supplied to houses from these transmission lines. usage of the power at homes there is a heavy load on these transformers. In this situation, BESCOM takes a decision to find the optimal way to reduce the load on the transformer's for each location in the city by placing NxN transformers in different wards. It so happens that due 3 to estr 193 Input format: The first line of the input consists of the number of cities and transformers present N. The next NxN lines are the values of the power units for each of the transformers. Sample Input 1: 4 82 83 69 92 77 37 49 92 11 69 5 86 89 98 23 Sample Output 1: 13 estree's 103382 The optimal power is calculated by first reducing the power by taking a minimum power unit value from the horizontally placed transformers followed by the vertically placed transformers in that ward. If any null power unit is available in the horizontal or vertical transformers then the power is supplied to these transformers excluding the others. This is followed in such a way that at least one or more than one null power units are available in the transmission lines. The power is supplied to the transformers to optimize the load. The remaining power units are re-routed to another city. Write a program to print the corresponding powerline to the respective ward through which the power is supplied to different homes. Input from STDIN (standard input) and Print to STDOUT (standard output) You should not write arbitrary strings while reading the input and while printing as these contribute to the standard output Constraints: 1) The placement of the transformers should be in an NxN form, 3 N 10. Previous Question 3318493 1033 Output format: The output format consists of the corresponding transformer for each city that is used to optimize the load. Print the transformer in the order of rows from 0 to n-1 restreet Next Question E6F8EL01260ES 10338493
Step by Step Solution
3.45 Rating (155 Votes )
There are 3 Steps involved in it
Heres a Python program that reads the input and calculates the correspondi... View full answer
Get step-by-step solutions from verified subject matter experts
