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: readmedit.m
    path of file: ./repos/fieldtrip/external/iso2mesh
    
    the code of the file until where you have to start completion: function [node,elem,face]=readmedit(filename)
%
% [node,elem,face]=readmedit(filename)
%
% read Medit mesh format
%
% author: Qianqian Fang, <q.fang at neu.edu>
%
% input:
%    fname: name of the medit data file
%
% output:
%    node: node coordinates of the mesh
%    elem: list of elements of the mesh	    
%    face: list of surface triangles of the mesh	    
%
% -- this function is part of iso2mesh toolbox (http://iso2mesh.sf.net)
%

node=[];

    
function [node,elem,face]=readmedit(filename)
%
% [node,elem,face]=readmedit(filename)
%
% read Medit mesh format
%
% author: Qianqian Fang, <q.fang at neu.edu>
%
% input:
%    fname: name of the medit data file
%
% output:
%    node: node coordinates of the mesh
%    elem: list of elements of the mesh	    
%    face: list of surface triangles of the mesh	    
%
% -- this function is part of iso2mesh toolbox (http://iso2mesh.sf.net)
%

node=[];
elem=[];
face=[];
fid=fopen(filename,'rt');
while(~feof(fid))
    key=fscanf(fid,'%s',1);
    if(strcmp(key,'End')) break; end