Your task is to swap adjacent letters in a RandomAccessFile. Simply read two bytes, back up by two bytes, and write the values out. If the file has an odd number of bytes, don't swap the last one. Also, don't swap byte pairs that contain the newline or return characters ('\n' or '\r'). If either byte of a pair equals one of these characters, skip the pair and move on to the next pair.

For example, when you process a file containing the text of a well-known childrens song, it will be transformed into

aMyrh daa l tilt ealbm,
ilttell ma,bl tilt ealbm,
aMyrh daa l tilt ealbm ,ti slfeeecw saw iheta  snswo.

Complete the following file:

TextMangler.java

import java.io.IOException; import java.io.RandomAccessFile; public class TextMangler { public static void swapAdjacentBytes(RandomAccessFile file) throws IOException { // TODO: complete } // this method checks your work public static void main(String[] args) throws IOException { RandomAccessFile file = new RandomAccessFile("data.txt", "rw"); swapAdjacentBytes(file); file.close(); } }