<html>
  <head>
    <meta content="text/html; charset=utf-8" http-equiv="Content-Type">
  </head>
  <body text="#000000" bgcolor="#FFFFFF">
    <div class="moz-cite-prefix">Of course I can, <br>
      <br>
      Here is the code so far. <br>
      <br>
      -module(module).<br>
      <br>
      -export([most_used_function_name/0]).<br>
      <br>
      most_used_function_name() -><br>
         process_module_data(code:all_loaded()).<br>
      <br>
      get_modules_name(Loaded_Modules_List) -><br>
          [ModuleName || {ModuleName, _} <- Loaded_Modules_List ]. <br>
          <br>
      get_functions_list(Module_List) -><br>
           ModuleList = [ Module:module_info(exports) || Module <-
      Module_List ].<br>
          <br>
      <br>
      process_module_data(Loaded_modules)  ->  <br>
          Module_List = get_modules_name(Loaded_modules),<br>
          Function_data = get_functions_list(Module_List).<br>
         <br>
      <br>
      Roelof<br>
      <br>
      <br>
      Op 18-8-2015 om 20:31 schreef Sean Cribbs:<br>
    </div>
    <blockquote
cite="mid:CAPGJuCat8Fh3CrEybVuy7f8P2Hz5GCnaPgKAGiAhGysOY+aRCw@mail.gmail.com"
      type="cite">
      <div dir="ltr">Can you give us an example of how you got the list
        of exports? That is, did you do something other than the below? 
        <div><br>
        </div>
        <div>Module:module_info(exports)</div>
        <div><br>
        </div>
        <div>Note that the Function/Arity notation is not a regular
          Erlang term, but becomes {Function, Arity} in the return value
          from module_info/1.</div>
      </div>
      <div class="gmail_extra"><br>
        <div class="gmail_quote">On Tue, Aug 18, 2015 at 1:13 PM, Roelof
          Wobben <span dir="ltr"><<a moz-do-not-send="true"
              href="mailto:r.wobben@home.nl" target="_blank">r.wobben@home.nl</a>></span>
          wrote:<br>
          <blockquote class="gmail_quote" style="margin:0 0 0
            .8ex;border-left:1px #ccc solid;padding-left:1ex">Hello,<br>
            <br>
            Im still trying to solve exercise 2 of chapter 8 of
            Programming erlang.<br>
            <br>
            Now I succeed in finding all functions that are exported by
            a module.<br>
            <br>
            I see now this output :<br>
            <br>
            [{get_rc,0}, {close,1}, {peername,1}, {setpeername,2},
            {peernames,...}, {...}|...],
            [{module,2},{module_info,0},{module_info,1}],
            [{new,0},{is_set,1},{size,...},{...}|...],
            [{server,3},{interfaces,...},{...}|...],
            [{init_it,...},{...}|...], [{...}|...], [...]|...]<br>
            <br>
            So I have list which are containing more list which contains
            one of more tuples<br>
            <br>
            Is it possible to convert this to for example [get_rc/0,
            peername/1, peernames/? , module/2 ]<br>
            <br>
            I tried with lists:flatten( name_of_list) but that one do
            not give me the right output.<br>
            <br>
            I need the nice output because I have to sort them and then
            count them.<br>
            <br>
            Roelof<br>
            <br>
            <br>
            ---<br>
            Dit e-mailbericht is gecontroleerd op virussen met Avast
            antivirussoftware.<br>
            <a moz-do-not-send="true"
              href="https://www.avast.com/antivirus" rel="noreferrer"
              target="_blank">https://www.avast.com/antivirus</a><br>
            <br>
            _______________________________________________<br>
            erlang-questions mailing list<br>
            <a moz-do-not-send="true"
              href="mailto:erlang-questions@erlang.org" target="_blank">erlang-questions@erlang.org</a><br>
            <a moz-do-not-send="true"
              href="http://erlang.org/mailman/listinfo/erlang-questions"
              rel="noreferrer" target="_blank">http://erlang.org/mailman/listinfo/erlang-questions</a><br>
          </blockquote>
        </div>
        <br>
      </div>
    </blockquote>
    <br>
  
<br /><br />
<hr style='border:none; color:#909090; background-color:#B0B0B0; height: 1px; width: 99%;' />
<table style='border-collapse:collapse;border:none;'>
        <tr>
                <td style='border:none;padding:0px 15px 0px 8px'>
                        <a href="https://www.avast.com/antivirus">
                                <img border=0 src="http://static.avast.com/emails/avast-mail-stamp.png" alt="Avast logo" />
                        </a>
                </td>
                <td>
                        <p style='color:#3d4d5a; font-family:"Calibri","Verdana","Arial","Helvetica"; font-size:12pt;'>
                                Dit e-mailbericht is gecontroleerd op virussen met Avast antivirussoftware.
                                <br><a href="https://www.avast.com/antivirus">www.avast.com</a>
                        </p>
                </td>
        </tr>
</table>
<br />
</body>
</html>