1

i have a very simple question,how can i convert and use this Pseudocode in c# code?

repeat
 i=i+1;
 until x[i]>=j

i mean what code in c# does the same work of this code?thanks

1
  • 1
    First you will need to define a non-pseudo x[] Commented Dec 19, 2010 at 10:34

2 Answers 2

8

You could use a do/while loop:

do {
    i++;
} while (x[i] < j);
Sign up to request clarification or add additional context in comments.

Comments

2

Also:

do {} while (x[++i] < j);

(Purely as a stylistic alternative)

1 Comment

Oh, so it is! Learn something new every day... :)

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Start asking to get answers

Find the answer to your question by asking.

Ask question

Explore related questions

See similar questions with these tags.