<SYSTEM_TASK:>
Solve the following problem using Python, implementing the functions described below, one line at a time
<END_TASK>
<USER_TASK:>
Description:
 def _write_executable_f90(self, execname, lines):
 """Appends the Fortran code to write the wrapper executable to the specified 'lines' list. :arg execname: the name of the executable in the self.module.executables to write. """

        executable = self.module.executables[execname]
            
        #The 14 in the formatting indent comes from 4 spaces, 2 from "_c", 1 from the spacing
        #between 'subroutine' and name of the executable, 10 from subroutine, 1 from the ("
        cparams = present_params(_ctypes_ex_parameters(executable), len(execname) + 14)
        lines.append("  subroutine {}_c({}) BIND(C)".format(execname, cparams))
        #Next, we add the variables declarations, the call to the original executable and then
        #the handling of the output variables.
        lines.append("    " + "\n    ".join(_ctypes_ex_variables(executable)))
        lines.append("    " + "\n    ".join(_ctypes_ex_compatvars(executable)))

        #Add assignment/allocate statements for the intent(in*) paramaters *local* variable
        #declarations so that we can match the signature exactly.
        lines.extend(_ctypes_ex_assign(executable))
                
        if type(executable).__name__  == "Subroutine":
            prefix = "call "
        else:
            prefix = "{}_f = ".format(execname)
            
        spacing = len(list(prefix)) + len(list(execname)) + 4
        lines.append("    {}{}({})".format(prefix, execname,
                                           present_params(executable.paramorder, spacing, 90)))
        lines.append("")
        lines.extend(_ctypes_ex_clean(executable))

        lines.append("  end subroutine {}_c\n".format(execname))