[Question]
  [
# Background
A few months ago, the adventure of your life was just about to start. Now, in this precise moment (yeah, now), after months of suffering and hard work, you and a group of friends are standing on the top of the world. Yes, you are right, you are on the summit of [Sagarmāthā](https://en.wikipedia.org/wiki/Mount_Everest).
However, things aren't going as well as you would like to. A dense fog has surrounded you and an incredibly bad-looking storm is coming as fast as it can. You didn't fix any rope on the way up, and your footprints have been covered in snow. If you want to survive (at least for today), you need to get out of there as fast as you can, but you MUST first find a way to know which face of the mountain is the one you should descend.
Luckily, you brought with you your [sat phone](https://en.wikipedia.org/wiki/Satellite_phone) which you modified before the trip so you are able to program and execute programs in it.
# Challenge
You have been able to download to your phone the map of the mountain in an ASCII-old-fashioned-unreadable-on-the-top-of-the-world way. Your task is to decide which face of the mountain presents the easiest descent so you can increase your chances of surviving. In order to do so, you have the brilliant idea to code a program on your phone that will tell which is the easiest way down. (Disclaimer: These activities have been done by professionals. No programmer was hurt during this narration. Please, do not try this at home.)
Maps are only made of the characters `/` and `\` (plus spaces and newlines).
In any map, the summit of the mountain is always represented by
```
 /\ 
 \/ 
```
and from each of the sides (`1,2,3` or `4`) of the summit you will always find a "possible" way down the mountain.
```
1 /\ 2
3 \/ 4
```
The routes are always presented in the next way:
```
                      \
  Steep-> /          /
           /        / <-Flat
            /      \
      Flat-> \    \
              /  \ <-Steep
               /\
               \/
```
where each new character is either one place to the left/right of its predecessor. The meaning of each character is:
* If the slash/backlash is parallel to its summit side -> counts as a 'steep' part.
* If the slash/backslash is perpendicular to its summit side -> counts as a 'flat' part.
\*For further reference see graphic above.
**Note**: The sides can have different lengths and the characters which constitute the summit also count as part of their side. In case of a draw, you can choose any of them.
[Standard loopholes](https://codegolf.meta.stackexchange.com/questions/1061/loopholes-that-are-forbidden-by-default) are disallowed.
# Input
A string representing the map of the mountain or a plain text file containing the same info.
Either
```
C:\....\file.txt
```
or
```
                  \
      /          /
       /        /
        /      \
         \    \
          /  \
           /\
           \/
          \  /
         \    \
        \      \
       \        \
      /          /
```
as a string are valid inputs.
# Output
As output, you should produce either a file in plain text or by stdout an **ASCII profile representation of the side with the smallest average steepness** using `_` for flat parts and `/` for steep parts **along with the average steepness** of the side `(number of "/")/(total chars)`.
Output example for map above:
```
       /
   ___/
  /
  AS:0.5
```
The format is not important as long as you have the profile and average steepness.
# Scoring
What? Do you want a better reward than saving your and your friend's lives and being the first programmer who has ever programmed on the top of the world? Okay... this is code golf, so shortest program in bytes wins.
# Test cases
Input:
```
                  \
      /          /
       /        /
        /      \
         \    \
          /  \
           /\
           \/
          \  /
         \    \
        \      \
       \        \
      /          /
```
Output:
```
       /
   ___/
  /
  AS=0.5
```
Input:
```
                  /
      \          /
       /        /
        \      /
         \    /
          /  /
           /\
           \/
          \  /
         \    \
        \      \
       \        \
      /          /
     / 
    / 
```
Output:
```
______/
AS=0.143 (1/7)
```
Input:
```
           /        \
            \      \
             /    /
              /  \
               /\
               \/
              \  /
             \    /
            \      /
           /        \
```
Output:
```
        /        
       /
      /       
    _/
    AS=0.8
```
  
[Answer]
# JavaScript (ES6), 303
Test running the snippet blow in an EcmaScript compliant browser - surely Firefox, probably Chrome. Using template strings, arrow functions.
```
// Golfed, no indentenation, all newlines are significant
f=s=>(s=`
${s}
`.split`
`,s.map((r,i)=>~(q=r.search(/\/\\/))&&(y=i,x=q),x=y=0),z=[],[0,2,0,2].map((d,i)=>{t=x+i%2,u=y+i/2|0,b=s[u][t];for(p=[''],n=l=0;(c=s[u][t])>' ';++l,t+=d-1,u+=(i&2)-1)c==b?p.push(p[n++].replace(/./g,' ',w='/')):w='_',p=p.map((r,i)=>(i<n?' ':w)+r);z=z[0]<(p[0]=n/l)?z:p}),z.join`
`)
// Less golfed
U=s=>(
  s=(`\n${s}\n`).split`\n`,
  x = y = 0,
  s.map((r,i)=>~(q=r.search(/\/\\/))&&(y=i,x=q)),
  z=[],
  [0,2,0,2].map((d,i) => {
    t = x+i%2,
    u = y+i/2|0,
    b = s[u][t];
    for(p=[''], n=l=0; (c=s[u][t])>' '; ++l, t += d-1, u +=(i&2)-1)
      c == b
        ? p.push(p[n++].replace(/./g,' ',w='/'))
        : w='_',
      p = p.map((r,i) => (i<n?' ':w)+r);
    z = z[0]<(p[0]=n/l)?z:p
  }),
  z.join`\n`
)
// TEST
// redirect console into the snippet body
console.log=x=>O.innerHTML+=x+'\n'
maps=[ // as javascript string literals, each baskslasch has to be repeated
`                  \\
      /          /
       /        /
        /      \\
         \\    \\
          /  \\
           /\\
           \\/
          \\  /
         \\    \\
        \\      \\
       \\        \\
      /          /`,
`                  /
      \\          /
       /        /
        \\      /
         \\    /
          /  /
           /\\
           \\/
          \\  /
         \\    \\
        \\      \\
       \\        \\
      /          /
     / 
    / `,
`           /        \\
            \\      \\
             /    /
              /  \\
               /\\
               \\/
              \\  /
             \\    /
            \\      /
           /        \\`]
maps.forEach(m=>console.log(m + '\n'+ f(m) +'\n'))
```
```
<pre id=O></pre>
```
]