You are an expert in writing code in many different languages. Your goal is to perform code completion for the following code, keeping in mind the rest of the code and the file meta data.
    Metadata details:
    filename: times.m
    path of file: ./repos/scGEAToolbox/tensor_toolbox/@ktensor
    
    the code of the file until where you have to start completion: function C = times(A, B)
%TIMES Element-wise multiplication for ktensor.
%
%   TIMES(A,B) denotes element-by-element multiplication (only supports the
%   second argument being a tensor or sptensor).
%
%   C = TIMES(A,B) is called for the syntax 'A .* B'. Either A or B must be
%   a tensor or sptensor.
%
%   See also KTENSOR, SPTENSOR/TIMES, TENSOR/TIMES.
%
%Tensor Toolbox for MATLAB: <a href="https://www.tensortoolbox.org">www.tensortoolbox.org</a>


    
function C = times(A, B)
%TIMES Element-wise multiplication for ktensor.
%
%   TIMES(A,B) denotes element-by-element multiplication (only supports the
%   second argument being a tensor or sptensor).
%
%   C = TIMES(A,B) is called for the syntax 'A .* B'. Either A or B must be
%   a tensor or sptensor.
%
%   See also KTENSOR, SPTENSOR/TIMES, TENSOR/TIMES.
%
%Tensor Toolbox for MATLAB: <a href="https://www.tensortoolbox.org">www.tensortoolbox.org</a>


if ~isequal(size(A), size(B))
    error('Must be two tensors of the same size');
end