How’s it going, I'm a Adam, a Full-Stack Engineer, actively searching for work. I'm all about JavaScript. And Frontend but don't let that fool you - I've also got some serious Backend skills.
Location
City of Bath, UK 🇬🇧
Education
10 plus years* active enterprise development experience and a Fine art degree 🎨
Funny you mention that, in C# they do have a parallel keyword.
Parallel.ForEach(files,(currentFile)=>{// The more computational work you do here, the greater// the speedup compared to a sequential foreach loop.stringfilename=Path.GetFileName(currentFile);varbitmap=newBitmap(currentFile);bitmap.RotateFlip(RotateFlipType.Rotate180FlipNone);bitmap.Save(Path.Combine(newDir,filename));// Peek behind the scenes to see how work is parallelized.// But be aware: Thread contention for the Console slows down parallel loops!!!Console.WriteLine($"Processing {filename} on thread {Thread.CurrentThread.ManagedThreadId}");//close lambda expression and method invocation});
For further actions, you may consider blocking this person and/or reporting abuse
We're a place where coders share, stay up-to-date and grow their careers.
If only there was a parallel keyword... Wait that would be stupid.
Funny you mention that, in C# they do have a parallel keyword.