Question: so I'm trying to remove several chars at an unknown index in a string.

The purpose of the program is to remove the character before "<".
So for example: *Te<st* should produce the output *Tst* so both E and < is removed from the string.
Also, it should be able to remove several occurrences of the "<".
For example, *This< is<< Text* should produce the output *Thi Text*

I've been trying to work around with char[] and StringBuilder but can't quite seem to get the hang of it.

I'm currently stuck with this code who doesn't do what I want it to do.

```
string input = Console.ReadLine();

        int indexLocation = input.IndexOf("<");
        int RemoveChar = indexLocation - 1; 
        Console.WriteLine(input.Remove(RemoveChar));

```

This doesn't work if the string has more than one "<" and if the "<" is in the middle of a sentence. For example *He<llo* the output is just *h*

Grateful for any answers or tips. I'm a beginner programmer.

Answer: 
They are the same operation. Both shift the bits to the left and adds a '0' to the LSB.
The purpose of arithmetic shift is to preserve the MSB.

In the case of a left shift, arithmetic and logic shift do the same operation.

In the case of a right shift, arithmetic shift preserves MSB and rest of the bits are shifted right

[Wikipedia article](https://en.wikipedia.org/wiki/Arithmetic_shift#Equivalence_of_arithmetic_and_logical_left_shifts_and_multiplication)