Lomuto Quicksort with Middle Pivot

Would it be possible? It seems to be very hard and inefficient to implement as we would have to track the location of the pivot and swap the pivot when the left and right pointers meet \ cross. There would be a trick of changing the first and middle elements and doing the original lomuto. I was just curious

Any way to remove spaces from the middle of dropdown values using SP 2010 workflows?

  1. I do not want to use 3rd party tools (like CodePlex).
  2. The value I want to manipulate is in a dropdown, so I can’t use calculated columns.
  3. There is no REPLACE function in SP 2010 Workflows.
  4. I am using SP Designer 2013 with SP 2010 Workflows.

I have searched for nearly 2 hours for some way to remove a space from a dropdown value in a SP 2010 Workflow. I have a hard time believing that it is impossible. There must be some way to do it. Can anyone help me figure out how to remove a space from a dropdown value in a SP 2010 Workflow if I do not know how many characters will be before and after the space?

Mouse: Middle click acts as primary click

I use a Lenovo Thinkpad keyboard with Trackpoint and an external Microsoft mouse with macOS Mojave. The middle click on the Thinkpad keyboard is used for scrolling when combined with Trackpoint movement. However, when the mouse pointer is on a clickable link (e.g. on a website), it also acts as the primary click. This results in the opening of lots of tabs in Firefox.

I tried clicking the middle button on the Microsoft mouse and it acted exactly the same. Is there any way to prevent the middle click of the external mouse not to act like the primary click?

Good Vs. Evil – Battle For Middle Earth – CodeWars

This is the code that I’m submitting for the “Good vs Evil” Kata on CodeWars:


function goodVsEvil(good, evil) {   good = good.split(' ');   evil = evil.split(' ');    //hobbits, men, elves, etc   let goodWorth = [1, 2, 3, 3, 4, 10];   //orcs, men, wargs, etc     let evilWorth = [1, 2, 2, 2, 3, 5, 10];    let goodArmyPoints = [];   //multiply goodWorth by type:   for (let i = 0; i < goodWorth.length; i++) {     goodArmyPoints.push(good[i] * goodWorth[i]);   }    goodArmyPoints = goodArmyPoints.reduce(function (sum, value) {     return sum + value;   });    let evilArmyPoints = [];   for (let j = 0; j < evilWorth.length; j++) {     evilArmyPoints.push(evil[j] * evilWorth[j]);   }    evilArmyPoints = evilArmyPoints.reduce(function (sum, value) {     return sum + value;   });    if (evilArmyPoints < goodArmyPoints) {     return "Battle Result: Good triumphs over Evil";   } else if (evilArmyPoints > goodArmyPoints) {     return "Battle Result: Evil eradicates all trace of Good";   } else {     return "Battle Result: No victor on this battle field";   }  } 

But I’m not sure what:

goodArmyPoints = goodArmyPoints.reduce(function (sum, value) {     return sum + value;   }); 

is doing exactly.

I see that reduce “executes a reducer function (which I’ve provided?) on each member of the array, resulting in a single output value”.

But can someone please walk me through what .reduce(function (sum, value) is doing, exactly? Where is this function coming from? What are sum and value?

I’m still learning JavaScript and this is new to me. Thanks.

Latency jumps in first, middle and last mile of path

I work for SD-WAN company providing an all in one solution edge router(Like FORTINET but not FORTINET).

We have one customer in particular that has such a hard time with our services i.e. gift card servers unreachable, credit card processor unreachable and sometimes the security cameras don’t send data back to the DC servers… Also the average ping to is about 36ms but the avg ping to GC or CC processors is usually greater than 100ms.

We use Linux based platform with alot of utilities based on Open standards, e.g OpenVPN.

WAN circuits are my area of troubleshooting. I run pings and traceroutes and sometimes I see some crazy things. I have some traceroutes below and would like to see if the collective experience and brain power of this community can offer some possibilities.

I’ve taken the GW IP out, the rest I don’t mind including.

Heres a good example of a clean traceroute to

  • Trace In Progress

traceroute to (, 30 hops max, 60 byte packets

1 x.x.x.x (x.x.x.x) 0.579 ms 0.679 ms 0.798 ms

2 76-202-64-1.lightspeed.brbnca.sbcglobal.net ( 24.986 ms 25.546 ms 25.666 ms

3 ( 20.833 ms 21.911 ms 22.035 ms

4 ( 24.520 ms 24.838 ms 26.063 ms

5 ( 30.335 ms ( 31.029 ms ( 30.416 ms

6 ggr2.la2ca.ip.att.net ( 31.437 ms 24.566 ms 21.605 ms

7 ( 23.534 ms 24.605 ms 25.294 ms

8 ae-2-70.edge3.LosAngeles1.Level3.net ( 27.329 ms ae-1-60.edge3.LosAngeles1.Level3.net ( 28.090 ms ae-2-70.edge3.LosAngeles1.Level3.net ( 28.782 ms

9 ae-2-70.edge3.LosAngeles1.Level3.net ( 28.938 ms ae-1-60.edge3.LosAngeles1.Level3.net ( 29.683 ms 30.287 ms

10 a.resolvers.level3.net ( 29.979 ms 30.654 ms 31.089 ms

Pretty good no problems. Lets look at the next example

This time an AT&T router’s latency jumps WAY UP

  • Trace In Progress

    traceroute to (, 30 hops max, 60 byte packets

1 x.x.x.x (x.x.x.x) 0.523 ms 0.637 ms 0.771 ms

2 76-202-64-1.lightspeed.brbnca.sbcglobal.net ( 19.439 ms 29.179 ms 38.125 ms

3 ( 20.750 ms 21.705 ms 22.158 ms

4 ( 24.994 ms 25.144 ms 27.133 ms

5 ( 29.790 ms 29.935 ms ( 31.198 ms

6 ggr2.la2ca.ip.att.net ( 32.876 ms 25.446 ms 280.808 ms

7 ( 279.921 ms 280.059 ms 281.683 ms

8 ae-2-70.edge3.LosAngeles1.Level3.net ( 282.984 ms ae-1-60.edge3.LosAngeles1.Level3.net ( 283.906 ms ae-2-70.edge3.LosAngeles1.Level3.net ( 284.473 ms

9 ae-1-60.edge3.LosAngeles1.Level3.net ( 285.152 ms ae-2-70.edge3.LosAngeles1.Level3.net ( 285.917 ms 286.054 ms

10 a.resolvers.level3.net ( 286.187 ms 286.935 ms 287.514 ms

IP Address: [ IP Lookup ] Hostname: IP Location: – United States (US) ISP: AT&T Services Organization: AT&T Internet Services

Well, this shows all sorts of latency in the First , Middle and Last mile.

  • Trace In Progress

    traceroute to (, 30 hops max, 60 byte packets

1 x.x.x.x (x.x.x.x) 0.539 ms 0.696 ms 0.837 ms

2 76-202-64-1.lightspeed.brbnca.sbcglobal.net ( 201.040 ms 201.634 ms 202.037 ms

3 ( 191.586 ms 192.707 ms 192.847 ms

4 ( 195.827

ms 196.305 ms 196.800 ms

5 ( 201.911 ms ( 201.063 ms ( 202.037 ms

6 ggr2.la2ca.ip.att.net ( 201.354 ms 222.888 ms 226.604 ms

7 ( 224.932 ms 222.087 ms 221.104 ms

8 ae-2-70.edge3.LosAngeles1.Level3.net ( 223.069 ms 220.636 ms ae-3-80.edge3.LosAngeles1.Level3.net ( 221.221 ms

9 ae-2-70.edge3.LosAngeles1.Level3.net ( 221.632 ms 233.260 ms 144.725 ms

10 a.resolvers.level3.net ( 143.808 ms 144.389 ms 144.739 ms

Finally this last one shows a First and Middle but not a Last mile issue:

  • Trace In Progress

    traceroute to (, 30 hops max, 60 byte packets

1 x.x.x.x (x.x.x.x) 1.184 ms 1.269 ms 1.408 ms

2 76-202-64-1.lightspeed.brbnca.sbcglobal.net ( 288.124 ms 288.613 ms 290.000 ms

3 ( 289.777 ms 302.201 ms 302.334 ms

4 ( 305.836 ms 309.880 ms 310.032 ms

5 ( 313.163 ms 312.685 ms 316.640 ms

6 ggr2.la2ca.ip.att.net ( 328.398 ms 421.902 ms 420.155 ms

7 ( 421.869 ms 21.274 ms 21.278 ms

8 ae-2-70.edge3.LosAngeles1.Level3.net ( 23.584 ms 25.078 ms ae-1-60.edge3.LosAngeles1.Level3.net ( 25.425 ms

9 ae-2-70.edge3.LosAngeles1.Level3.net ( 26.380 ms 27.567 ms 28.278 ms

10 a.resolvers.level3.net ( 27.654 ms 28.365 ms 28.907 ms

If anyone can offer any insight on this circuit or path issue please give me some ideas… Thank you

Finding the reason behind an RDP Certificate Change (man in the middle attack?)

I’ve installed some new networking equipment: firewall, switches, vlans, etc. I won’t mention the brand name here, because I don’t want to cause them harm by my suspicions.

Right after doing this, I was able to RDP to a server inside my LAN without being prompted for a finger print change.

One day later, however, as I try to connect to that same server, it is now prompting me to accept a new certificate because the fingerprint has changed.

I have a suspicion that the new networking equipment is trying to gather the credentials of my servers by intercepting my RDP sessions in a manner that would be otherwise transparent except for the fact that I’m being prompt to accept a changed certificate.

How can I confirm that this finger print change’s source is something that has occurred on the server I’m connecting to, and not due to the new networking equipment trying to do a man in the middle attack to catalog credentials on my network (that it should not be curious about)?

Middle Name missing on Cathay Pacific Ticket [duplicate]

This question already has an answer here:

  • Bought a ticket with Finnair, didn't enter my middle name 5 answers

I recently booked a ticket through a travel agent which didn’t ask for my middle name, and I’ve been told by a friend that I may run into problems because it doesn’t exactly match the name on my passport.

In the blog mention in this answer it says that lacking a middle name on an airline ticket rarely causes any issues, however the first comment mentions that Cathay Pacific (CX) does require this.

I’ve emailed Cathay and they ‘advise that the ticket should fully match the name in the passport’, but I was wondering if anyone had run into any problems with Cathay and missing middle names?

I’ve also emailed the travel agent to see if they could change the ticket, but I don’t know if they would charge for re-issuing the ticket.