Copies the array. - CSharp System

CSharp examples for System:Array Element

Description

Copies the array.

Demo Code


using System.Collections.Generic;
using System.Collections;
using System;/*www .j a  v a2s.c  o  m*/

public class Main{
        /// <summary>
        /// Copies the array.
        /// </summary>
        /// <param name="src">The SRC.</param>
        /// <param name="dest">The dest.</param>
        /// <param name="start">The start.</param>
        public static void CopyArray(byte[] src, byte[] dest, int start)
        {
            int j = 0;
            for (int i = start; i < start + dest.Length; i++)
            {
                dest[j++] = src[i];
            }
        }
}

Related Tutorials