solidity 编写遇到的问题

1.函数想返回  msg.sender 怎么返回?

想把msg.sender 换成 string ,奈何无法转换,直接返回 uint 又不行

 

pragma solidity ^0.5.12;

contract student_daka{
    
    uint public TotalCount ;
    
    struct stu{
        
        string namee;
        string timee;
        string timess;
        
    }
    
    string public xx ;
    
    uint  public x = uint(msg.sender);
    
    //stu[] public stuss;
    
    //mapping(uint => uint )public stu_times;    
    
    function search()  public returns (uint){
        //string memory ss = msg.sender;
        //return "xxxxxxxxxxxxsss";
        return uint(msg.sender);
    }
    
}

 

上一篇:c++实现信号槽


下一篇:Python轻应用有哪些过人之处?