import java.awt.Point;
import java.io.*;
import java.util.*;
import java.math.BigInteger;

public class Main {
    static class Solver {
        public void solve(MyReader in, PrintWriter out) {
            String s = in.next();
            int n = s.length();

            boolean res = isPali(s);
            String a = (s.substring(0,(n-1)/2));
//            out.println(a.toString());
            if (!isPali(a))res = false;

            int pos = (n+3)/2 - 1;
            String b = (s.substring(pos));
//            out.println(b.toString());
            if (!isPali(b))res = false;


            if (res)out.println("Yes");
            else out.println("No");


        }

        private boolean isPali(String a) {
            int l = 0,r = a.length()-1;
            while (l<r){
                if (a.charAt(l) != a.charAt(r))return false;
                l++;
                r--;
            }

            return true;
        }


    }

    public static void main(String[] args) {
        MyReader mr = new MyReader();
        PrintWriter out = new PrintWriter(new OutputStreamWriter(System.out));
        new Solver().solve(mr, out);
        out.close();
    }

    //    static int[][] dir = {{0,1}, {1,0},{-1,0}, {0,-1}};
//    static int[][] dir = {{0,1}, {1,0},{-1,0}, {0,-1}, {-1,-1},{-1,1}, {1,1}, {1,-1}};
    static class MyReader {
        BufferedReader br;
        StringTokenizer st;

        MyReader() {
            br = new BufferedReader(new InputStreamReader(System.in));
        }

        String next() {
            while (st == null || !st.hasMoreElements()) {
                try {
                    st = new StringTokenizer(br.readLine());
                } catch (Exception e) {
                    e.printStackTrace();
                }
            }

            return st.nextToken();
        }

        int nextInt() {
            return Integer.parseInt(next());
        }

        long nextLong() {
            return Long.parseLong(next());
        }

        double nextDouble() {
            return Double.parseDouble(next());
        }

        String nextLine() {
            String res = "";
            try {
                res = br.readLine();
            } catch (IOException e) {
                e.printStackTrace();
            }

            return res;
        }

        int[] nextIntArray(int n) {
            int[] arr = new int[n];
            for (int i = 0; i < n; i++) {
                arr[i] = nextInt();
            }

            return arr;
        }

        Integer[] nextIntegerArray(int n) {
            Integer[] arr = new Integer[n];
            for (int i = 0; i < n; i++) {
                arr[i] = nextInt();
            }

            return arr;
        }

        Long[] nextLongArray(int n) {
            Long[] arr = new Long[n];
            for (int i = 0; i < n; i++) {
                arr[i] = nextLong();
            }

            return arr;
        }

        String[] nextStringArray(int n) {
            String[] arr = new String[n];
            for (int i = 0; i < n; i++) {
                arr[i] = next();
            }
            return arr;
        }
    }

    static void swap(int[] arr, int i, int j) {
        int tmp = arr[i];
        arr[i] = arr[j];
        arr[j] = tmp;
    }

}

 import java.awt.Point; Point java.awt import java.io.*; io.* java import java.util.*; util.* java import java.math.BigInteger; BigInteger java.math public class Main {
    static class Solver {
        public void solve(MyReader in, PrintWriter out) {
            String s = in.next();
            int n = s.length();

            boolean res = isPali(s);
            String a = (s.substring(0,(n-1)/2));
//            out.println(a.toString());
            if (!isPali(a))res = false;

            int pos = (n+3)/2 - 1;
            String b = (s.substring(pos));
//            out.println(b.toString());
            if (!isPali(b))res = false;


            if (res)out.println("Yes");
            else out.println("No");


        }

        private boolean isPali(String a) {
            int l = 0,r = a.length()-1;
            while (l<r){
                if (a.charAt(l) != a.charAt(r))return false;
                l++;
                r--;
            }

            return true;
        }


    }

    public static void main(String[] args) {
        MyReader mr = new MyReader();
        PrintWriter out = new PrintWriter(new OutputStreamWriter(System.out));
        new Solver().solve(mr, out);
        out.close();
    }

    //    static int[][] dir = {{0,1}, {1,0},{-1,0}, {0,-1}};
//    static int[][] dir = {{0,1}, {1,0},{-1,0}, {0,-1}, {-1,-1},{-1,1}, {1,1}, {1,-1}};
    static class MyReader {
        BufferedReader br;
        StringTokenizer st;

        MyReader() {
            br = new BufferedReader(new InputStreamReader(System.in));
        }

        String next() {
            while (st == null || !st.hasMoreElements()) {
                try {
                    st = new StringTokenizer(br.readLine());
                } catch (Exception e) {
                    e.printStackTrace();
                }
            }

            return st.nextToken();
        }

        int nextInt() {
            return Integer.parseInt(next());
        }

        long nextLong() {
            return Long.parseLong(next());
        }

        double nextDouble() {
            return Double.parseDouble(next());
        }

        String nextLine() {
            String res = "";
            try {
                res = br.readLine();
            } catch (IOException e) {
                e.printStackTrace();
            }

            return res;
        }

        int[] nextIntArray(int n) {
            int[] arr = new int[n];
            for (int i = 0; i < n; i++) {
                arr[i] = nextInt();
            }

            return arr;
        }

        Integer[] nextIntegerArray(int n) {
            Integer[] arr = new Integer[n];
            for (int i = 0; i < n; i++) {
                arr[i] = nextInt();
            }

            return arr;
        }

        Long[] nextLongArray(int n) {
            Long[] arr = new Long[n];
            for (int i = 0; i < n; i++) {
                arr[i] = nextLong();
            }

            return arr;
        }

        String[] nextStringArray(int n) {
            String[] arr = new String[n];
            for (int i = 0; i < n; i++) {
                arr[i] = next();
            }
            return arr;
        }
    }

    static void swap(int[] arr, int i, int j) {
        int tmp = arr[i];
        arr[i] = arr[j];
        arr[j] = tmp;
    }

} Main public static void main(String[] args) {
        MyReader mr = new MyReader();
        PrintWriter out = new PrintWriter(new OutputStreamWriter(System.out));
        new Solver().solve(mr, out);
        out.close();
    } main {
        MyReader mr = new MyReader();
        PrintWriter out = new PrintWriter(new OutputStreamWriter(System.out));
        new Solver().solve(mr, out);
        out.close();
    } MyReader mr = new MyReader(); mr new MyReader() PrintWriter out = new PrintWriter(new OutputStreamWriter(System.out)); out new PrintWriter(new OutputStreamWriter(System.out)) new Solver().solve(mr, out) new Solver().solve new Solver() mr out out.close() out.close out String[] args args static void swap(int[] arr, int i, int j) {
        int tmp = arr[i];
        arr[i] = arr[j];
        arr[j] = tmp;
    } swap {
        int tmp = arr[i];
        arr[i] = arr[j];
        arr[j] = tmp;
    } int tmp = arr[i]; tmp arr[i] arr i arr[i] = arr[j] arr[i] arr i arr[j] arr j arr[j] = tmp arr[j] arr j tmp int[] arr arr int i i int j j static class Solver {
        public void solve(MyReader in, PrintWriter out) {
            String s = in.next();
            int n = s.length();

            boolean res = isPali(s);
            String a = (s.substring(0,(n-1)/2));
//            out.println(a.toString());
            if (!isPali(a))res = false;

            int pos = (n+3)/2 - 1;
            String b = (s.substring(pos));
//            out.println(b.toString());
            if (!isPali(b))res = false;


            if (res)out.println("Yes");
            else out.println("No");


        }

        private boolean isPali(String a) {
            int l = 0,r = a.length()-1;
            while (l<r){
                if (a.charAt(l) != a.charAt(r))return false;
                l++;
                r--;
            }

            return true;
        }


    } Solver public void solve(MyReader in, PrintWriter out) {
            String s = in.next();
            int n = s.length();

            boolean res = isPali(s);
            String a = (s.substring(0,(n-1)/2));
//            out.println(a.toString());
            if (!isPali(a))res = false;

            int pos = (n+3)/2 - 1;
            String b = (s.substring(pos));
//            out.println(b.toString());
            if (!isPali(b))res = false;


            if (res)out.println("Yes");
            else out.println("No");


        } solve {
            String s = in.next();
            int n = s.length();

            boolean res = isPali(s);
            String a = (s.substring(0,(n-1)/2));
//            out.println(a.toString());
            if (!isPali(a))res = false;

            int pos = (n+3)/2 - 1;
            String b = (s.substring(pos));
//            out.println(b.toString());
            if (!isPali(b))res = false;


            if (res)out.println("Yes");
            else out.println("No");


        } String s = in.next(); s in.next() in.next in int n = s.length(); n s.length() s.length s boolean res = isPali(s); res isPali(s) isPali s String a = (s.substring(0,(n-1)/2)); a (s.substring(0,(n-1)/2)) s.substring s 0 (n-1)/2 (n-1) n 1 2 if (!isPali(a))res = false; !isPali(a) isPali(a) isPali a res = false res false int pos = (n+3)/2 - 1; pos (n+3)/2 - 1 (n+3)/2 (n+3) n 3 2 1 String b = (s.substring(pos)); b (s.substring(pos)) s.substring s pos if (!isPali(b))res = false; !isPali(b) isPali(b) isPali b res = false res false if (res)out.println("Yes");
            else out.println("No"); res out.println("Yes") out.println out "Yes" out.println("No") out.println out "No" MyReader in in PrintWriter out out private boolean isPali(String a) {
            int l = 0,r = a.length()-1;
            while (l<r){
                if (a.charAt(l) != a.charAt(r))return false;
                l++;
                r--;
            }

            return true;
        } isPali {
            int l = 0,r = a.length()-1;
            while (l<r){
                if (a.charAt(l) != a.charAt(r))return false;
                l++;
                r--;
            }

            return true;
        } int l = 0 l 0 r = a.length()-1; r a.length()-1 a.length() a.length a 1 while (l<r){
                if (a.charAt(l) != a.charAt(r))return false;
                l++;
                r--;
            } l<r l r {
                if (a.charAt(l) != a.charAt(r))return false;
                l++;
                r--;
            } if (a.charAt(l) != a.charAt(r))return false; a.charAt(l) != a.charAt(r) a.charAt(l) a.charAt a l a.charAt(r) a.charAt a r return false; false l++ l r-- r return true; true String a a static class MyReader {
        BufferedReader br;
        StringTokenizer st;

        MyReader() {
            br = new BufferedReader(new InputStreamReader(System.in));
        }

        String next() {
            while (st == null || !st.hasMoreElements()) {
                try {
                    st = new StringTokenizer(br.readLine());
                } catch (Exception e) {
                    e.printStackTrace();
                }
            }

            return st.nextToken();
        }

        int nextInt() {
            return Integer.parseInt(next());
        }

        long nextLong() {
            return Long.parseLong(next());
        }

        double nextDouble() {
            return Double.parseDouble(next());
        }

        String nextLine() {
            String res = "";
            try {
                res = br.readLine();
            } catch (IOException e) {
                e.printStackTrace();
            }

            return res;
        }

        int[] nextIntArray(int n) {
            int[] arr = new int[n];
            for (int i = 0; i < n; i++) {
                arr[i] = nextInt();
            }

            return arr;
        }

        Integer[] nextIntegerArray(int n) {
            Integer[] arr = new Integer[n];
            for (int i = 0; i < n; i++) {
                arr[i] = nextInt();
            }

            return arr;
        }

        Long[] nextLongArray(int n) {
            Long[] arr = new Long[n];
            for (int i = 0; i < n; i++) {
                arr[i] = nextLong();
            }

            return arr;
        }

        String[] nextStringArray(int n) {
            String[] arr = new String[n];
            for (int i = 0; i < n; i++) {
                arr[i] = next();
            }
            return arr;
        }
    } MyReader BufferedReader br; br StringTokenizer st; st MyReader() {
            br = new BufferedReader(new InputStreamReader(System.in));
        } MyReader {
            br = new BufferedReader(new InputStreamReader(System.in));
        } br = new BufferedReader(new InputStreamReader(System.in)) br new BufferedReader(new InputStreamReader(System.in)) String next() {
            while (st == null || !st.hasMoreElements()) {
                try {
                    st = new StringTokenizer(br.readLine());
                } catch (Exception e) {
                    e.printStackTrace();
                }
            }

            return st.nextToken();
        } next {
            while (st == null || !st.hasMoreElements()) {
                try {
                    st = new StringTokenizer(br.readLine());
                } catch (Exception e) {
                    e.printStackTrace();
                }
            }

            return st.nextToken();
        } while (st == null || !st.hasMoreElements()) {
                try {
                    st = new StringTokenizer(br.readLine());
                } catch (Exception e) {
                    e.printStackTrace();
                }
            } st == null || !st.hasMoreElements() st == null st null !st.hasMoreElements() st.hasMoreElements() st.hasMoreElements st {
                try {
                    st = new StringTokenizer(br.readLine());
                } catch (Exception e) {
                    e.printStackTrace();
                }
            } try {
                    st = new StringTokenizer(br.readLine());
                } catch (Exception e) {
                    e.printStackTrace();
                } catch (Exception e) {
                    e.printStackTrace();
                } Exception e {
                    e.printStackTrace();
                } e.printStackTrace() e.printStackTrace e {
                    st = new StringTokenizer(br.readLine());
                } st = new StringTokenizer(br.readLine()) st new StringTokenizer(br.readLine()) return st.nextToken(); st.nextToken() st.nextToken st int nextInt() {
            return Integer.parseInt(next());
        } nextInt {
            return Integer.parseInt(next());
        } return Integer.parseInt(next()); Integer.parseInt(next()) Integer.parseInt Integer next() next long nextLong() {
            return Long.parseLong(next());
        } nextLong {
            return Long.parseLong(next());
        } return Long.parseLong(next()); Long.parseLong(next()) Long.parseLong Long next() next double nextDouble() {
            return Double.parseDouble(next());
        } nextDouble {
            return Double.parseDouble(next());
        } return Double.parseDouble(next()); Double.parseDouble(next()) Double.parseDouble Double next() next String nextLine() {
            String res = "";
            try {
                res = br.readLine();
            } catch (IOException e) {
                e.printStackTrace();
            }

            return res;
        } nextLine {
            String res = "";
            try {
                res = br.readLine();
            } catch (IOException e) {
                e.printStackTrace();
            }

            return res;
        } String res = ""; res "" try {
                res = br.readLine();
            } catch (IOException e) {
                e.printStackTrace();
            } catch (IOException e) {
                e.printStackTrace();
            } IOException e {
                e.printStackTrace();
            } e.printStackTrace() e.printStackTrace e {
                res = br.readLine();
            } res = br.readLine() res br.readLine() br.readLine br return res; res int[] nextIntArray(int n) {
            int[] arr = new int[n];
            for (int i = 0; i < n; i++) {
                arr[i] = nextInt();
            }

            return arr;
        } nextIntArray {
            int[] arr = new int[n];
            for (int i = 0; i < n; i++) {
                arr[i] = nextInt();
            }

            return arr;
        } int[] arr = new int[n]; arr new int[n] n for (int i = 0; i < n; i++) {
                arr[i] = nextInt();
            } int i = 0; int i = 0; i 0 i < n i n i++ i++ i {
                arr[i] = nextInt();
            } {
                arr[i] = nextInt();
            } arr[i] = nextInt() arr[i] arr i nextInt() nextInt return arr; arr int n n Integer[] nextIntegerArray(int n) {
            Integer[] arr = new Integer[n];
            for (int i = 0; i < n; i++) {
                arr[i] = nextInt();
            }

            return arr;
        } nextIntegerArray {
            Integer[] arr = new Integer[n];
            for (int i = 0; i < n; i++) {
                arr[i] = nextInt();
            }

            return arr;
        } Integer[] arr = new Integer[n]; arr new Integer[n] n for (int i = 0; i < n; i++) {
                arr[i] = nextInt();
            } int i = 0; int i = 0; i 0 i < n i n i++ i++ i {
                arr[i] = nextInt();
            } {
                arr[i] = nextInt();
            } arr[i] = nextInt() arr[i] arr i nextInt() nextInt return arr; arr int n n Long[] nextLongArray(int n) {
            Long[] arr = new Long[n];
            for (int i = 0; i < n; i++) {
                arr[i] = nextLong();
            }

            return arr;
        } nextLongArray {
            Long[] arr = new Long[n];
            for (int i = 0; i < n; i++) {
                arr[i] = nextLong();
            }

            return arr;
        } Long[] arr = new Long[n]; arr new Long[n] n for (int i = 0; i < n; i++) {
                arr[i] = nextLong();
            } int i = 0; int i = 0; i 0 i < n i n i++ i++ i {
                arr[i] = nextLong();
            } {
                arr[i] = nextLong();
            } arr[i] = nextLong() arr[i] arr i nextLong() nextLong return arr; arr int n n String[] nextStringArray(int n) {
            String[] arr = new String[n];
            for (int i = 0; i < n; i++) {
                arr[i] = next();
            }
            return arr;
        } nextStringArray {
            String[] arr = new String[n];
            for (int i = 0; i < n; i++) {
                arr[i] = next();
            }
            return arr;
        } String[] arr = new String[n]; arr new String[n] n for (int i = 0; i < n; i++) {
                arr[i] = next();
            } int i = 0; int i = 0; i 0 i < n i n i++ i++ i {
                arr[i] = next();
            } {
                arr[i] = next();
            } arr[i] = next() arr[i] arr i next() next return arr; arr int n n public class Main {
    static class Solver {
        public void solve(MyReader in, PrintWriter out) {
            String s = in.next();
            int n = s.length();

            boolean res = isPali(s);
            String a = (s.substring(0,(n-1)/2));
//            out.println(a.toString());
            if (!isPali(a))res = false;

            int pos = (n+3)/2 - 1;
            String b = (s.substring(pos));
//            out.println(b.toString());
            if (!isPali(b))res = false;


            if (res)out.println("Yes");
            else out.println("No");


        }

        private boolean isPali(String a) {
            int l = 0,r = a.length()-1;
            while (l<r){
                if (a.charAt(l) != a.charAt(r))return false;
                l++;
                r--;
            }

            return true;
        }


    }

    public static void main(String[] args) {
        MyReader mr = new MyReader();
        PrintWriter out = new PrintWriter(new OutputStreamWriter(System.out));
        new Solver().solve(mr, out);
        out.close();
    }

    //    static int[][] dir = {{0,1}, {1,0},{-1,0}, {0,-1}};
//    static int[][] dir = {{0,1}, {1,0},{-1,0}, {0,-1}, {-1,-1},{-1,1}, {1,1}, {1,-1}};
    static class MyReader {
        BufferedReader br;
        StringTokenizer st;

        MyReader() {
            br = new BufferedReader(new InputStreamReader(System.in));
        }

        String next() {
            while (st == null || !st.hasMoreElements()) {
                try {
                    st = new StringTokenizer(br.readLine());
                } catch (Exception e) {
                    e.printStackTrace();
                }
            }

            return st.nextToken();
        }

        int nextInt() {
            return Integer.parseInt(next());
        }

        long nextLong() {
            return Long.parseLong(next());
        }

        double nextDouble() {
            return Double.parseDouble(next());
        }

        String nextLine() {
            String res = "";
            try {
                res = br.readLine();
            } catch (IOException e) {
                e.printStackTrace();
            }

            return res;
        }

        int[] nextIntArray(int n) {
            int[] arr = new int[n];
            for (int i = 0; i < n; i++) {
                arr[i] = nextInt();
            }

            return arr;
        }

        Integer[] nextIntegerArray(int n) {
            Integer[] arr = new Integer[n];
            for (int i = 0; i < n; i++) {
                arr[i] = nextInt();
            }

            return arr;
        }

        Long[] nextLongArray(int n) {
            Long[] arr = new Long[n];
            for (int i = 0; i < n; i++) {
                arr[i] = nextLong();
            }

            return arr;
        }

        String[] nextStringArray(int n) {
            String[] arr = new String[n];
            for (int i = 0; i < n; i++) {
                arr[i] = next();
            }
            return arr;
        }
    }

    static void swap(int[] arr, int i, int j) {
        int tmp = arr[i];
        arr[i] = arr[j];
        arr[j] = tmp;
    }

} public class Main {
    static class Solver {
        public void solve(MyReader in, PrintWriter out) {
            String s = in.next();
            int n = s.length();

            boolean res = isPali(s);
            String a = (s.substring(0,(n-1)/2));
//            out.println(a.toString());
            if (!isPali(a))res = false;

            int pos = (n+3)/2 - 1;
            String b = (s.substring(pos));
//            out.println(b.toString());
            if (!isPali(b))res = false;


            if (res)out.println("Yes");
            else out.println("No");


        }

        private boolean isPali(String a) {
            int l = 0,r = a.length()-1;
            while (l<r){
                if (a.charAt(l) != a.charAt(r))return false;
                l++;
                r--;
            }

            return true;
        }


    }

    public static void main(String[] args) {
        MyReader mr = new MyReader();
        PrintWriter out = new PrintWriter(new OutputStreamWriter(System.out));
        new Solver().solve(mr, out);
        out.close();
    }

    //    static int[][] dir = {{0,1}, {1,0},{-1,0}, {0,-1}};
//    static int[][] dir = {{0,1}, {1,0},{-1,0}, {0,-1}, {-1,-1},{-1,1}, {1,1}, {1,-1}};
    static class MyReader {
        BufferedReader br;
        StringTokenizer st;

        MyReader() {
            br = new BufferedReader(new InputStreamReader(System.in));
        }

        String next() {
            while (st == null || !st.hasMoreElements()) {
                try {
                    st = new StringTokenizer(br.readLine());
                } catch (Exception e) {
                    e.printStackTrace();
                }
            }

            return st.nextToken();
        }

        int nextInt() {
            return Integer.parseInt(next());
        }

        long nextLong() {
            return Long.parseLong(next());
        }

        double nextDouble() {
            return Double.parseDouble(next());
        }

        String nextLine() {
            String res = "";
            try {
                res = br.readLine();
            } catch (IOException e) {
                e.printStackTrace();
            }

            return res;
        }

        int[] nextIntArray(int n) {
            int[] arr = new int[n];
            for (int i = 0; i < n; i++) {
                arr[i] = nextInt();
            }

            return arr;
        }

        Integer[] nextIntegerArray(int n) {
            Integer[] arr = new Integer[n];
            for (int i = 0; i < n; i++) {
                arr[i] = nextInt();
            }

            return arr;
        }

        Long[] nextLongArray(int n) {
            Long[] arr = new Long[n];
            for (int i = 0; i < n; i++) {
                arr[i] = nextLong();
            }

            return arr;
        }

        String[] nextStringArray(int n) {
            String[] arr = new String[n];
            for (int i = 0; i < n; i++) {
                arr[i] = next();
            }
            return arr;
        }
    }

    static void swap(int[] arr, int i, int j) {
        int tmp = arr[i];
        arr[i] = arr[j];
        arr[j] = tmp;
    }

} Main
import java.awt.Point;
import java.io.*;
import java.util.*;
import java.math.BigInteger;

public class Main {
    static class Solver {
        public void solve(MyReader in, PrintWriter out) {
            String s = in.next();
            int n = s.length();

            boolean res = isPali(s);
            String a = (s.substring(0,(n-1)/2));
//            out.println(a.toString());
            if (!isPali(a))res = false;

            int pos = (n+3)/2 - 1;
            String b = (s.substring(pos));
//            out.println(b.toString());
            if (!isPali(b))res = false;


            if (res)out.println("Yes");
            else out.println("No");


        }

        private boolean isPali(String a) {
            int l = 0,r = a.length()-1;
            while (l<r){
                if (a.charAt(l) != a.charAt(r))return false;
                l++;
                r--;
            }

            return true;
        }


    }

    public static void main(String[] args) {
        MyReader mr = new MyReader();
        PrintWriter out = new PrintWriter(new OutputStreamWriter(System.out));
        new Solver().solve(mr, out);
        out.close();
    }

    //    static int[][] dir = {{0,1}, {1,0},{-1,0}, {0,-1}};
//    static int[][] dir = {{0,1}, {1,0},{-1,0}, {0,-1}, {-1,-1},{-1,1}, {1,1}, {1,-1}};
    static class MyReader {
        BufferedReader br;
        StringTokenizer st;

        MyReader() {
            br = new BufferedReader(new InputStreamReader(System.in));
        }

        String next() {
            while (st == null || !st.hasMoreElements()) {
                try {
                    st = new StringTokenizer(br.readLine());
                } catch (Exception e) {
                    e.printStackTrace();
                }
            }

            return st.nextToken();
        }

        int nextInt() {
            return Integer.parseInt(next());
        }

        long nextLong() {
            return Long.parseLong(next());
        }

        double nextDouble() {
            return Double.parseDouble(next());
        }

        String nextLine() {
            String res = "";
            try {
                res = br.readLine();
            } catch (IOException e) {
                e.printStackTrace();
            }

            return res;
        }

        int[] nextIntArray(int n) {
            int[] arr = new int[n];
            for (int i = 0; i < n; i++) {
                arr[i] = nextInt();
            }

            return arr;
        }

        Integer[] nextIntegerArray(int n) {
            Integer[] arr = new Integer[n];
            for (int i = 0; i < n; i++) {
                arr[i] = nextInt();
            }

            return arr;
        }

        Long[] nextLongArray(int n) {
            Long[] arr = new Long[n];
            for (int i = 0; i < n; i++) {
                arr[i] = nextLong();
            }

            return arr;
        }

        String[] nextStringArray(int n) {
            String[] arr = new String[n];
            for (int i = 0; i < n; i++) {
                arr[i] = next();
            }
            return arr;
        }
    }

    static void swap(int[] arr, int i, int j) {
        int tmp = arr[i];
        arr[i] = arr[j];
        arr[j] = tmp;
    }

}


